From 99389748beb0158811505efa606c27e1e2e0bc7b Mon Sep 17 00:00:00 2001 From: Stanislav Laznicka Date: Apr 03 2017 13:06:53 +0000 Subject: Remove publish_ca_cert() method from NSSDatabase NSSDatabase.publish_ca_cert() is not used anymore, remove it. https://pagure.io/freeipa/issue/6806 Reviewed-By: Jan Cholasta --- diff --git a/ipapython/certdb.py b/ipapython/certdb.py index f1410e5..0665f94 100644 --- a/ipapython/certdb.py +++ b/ipapython/certdb.py @@ -596,12 +596,3 @@ class NSSDatabase(object): finally: del certdb, cert nss.nss_shutdown() - - def publish_ca_cert(self, canickname, location): - args = ["-L", "-n", canickname, "-a"] - result = self.run_certutil(args, capture_output=True) - cert = result.output - fd = open(location, "w+") - fd.write(cert) - fd.close() - os.chmod(location, 0o444) diff --git a/ipaserver/install/certs.py b/ipaserver/install/certs.py index 0ca9713..16139f8 100644 --- a/ipaserver/install/certs.py +++ b/ipaserver/install/certs.py @@ -640,9 +640,6 @@ class CertDB(object): self.export_ca_cert(nickname, False) - def publish_ca_cert(self, location): - self.nssdb.publish_ca_cert(self.cacert_name, location) - def export_pem_cert(self, nickname, location): return self.nssdb.export_pem_cert(nickname, location)