diff options
Diffstat (limited to 'ipalib/x509.py')
-rw-r--r-- | ipalib/x509.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/ipalib/x509.py b/ipalib/x509.py index 1274673c..1b133adf 100644 --- a/ipalib/x509.py +++ b/ipalib/x509.py @@ -141,6 +141,14 @@ def get_subject(certificate, datatype=PEM, dbdir=None): nsscert = load_certificate(certificate, datatype, dbdir) return nsscert.subject +def get_issuer(certificate, datatype=PEM, dbdir=None): + """ + Load an X509.3 certificate and get the issuer. + """ + + nsscert = load_certificate(certificate, datatype, dbdir) + return nsscert.issuer + def get_serial_number(certificate, datatype=PEM, dbdir=None): """ Return the decimal value of the serial number. |