summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlex Gaynor <alex.gaynor@gmail.com>2016-06-02 09:12:10 -0700
committerAlex Gaynor <alex.gaynor@gmail.com>2016-06-02 09:12:10 -0700
commit39ea5314e738ffb6455afe1df2e99f69a2aeb465 (patch)
treea82dc2a734602bf3be6a6ec9182feeed5d9025eb
parent0f11ab36e36073e4cfeb23d476c4e6940671a263 (diff)
downloadpyopenssl-39ea5314e738ffb6455afe1df2e99f69a2aeb465.tar.gz
X509 sigalg is now opaque
-rw-r--r--src/OpenSSL/crypto.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/OpenSSL/crypto.py b/src/OpenSSL/crypto.py
index 964420c..d6ebb22 100644
--- a/src/OpenSSL/crypto.py
+++ b/src/OpenSSL/crypto.py
@@ -1081,8 +1081,8 @@ class X509(object):
.. versionadded:: 0.13
"""
- alg = self._x509.cert_info.signature.algorithm
- nid = _lib.OBJ_obj2nid(alg)
+ algor = _lib.X509_get0_tbs_sigalg(self._x509)
+ nid = _lib.OBJ_obj2nid(algor.algorithm)
if nid == _lib.NID_undef:
raise ValueError("Undefined signature algorithm")
return _ffi.string(_lib.OBJ_nid2ln(nid))