aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPaul Kehrer <paul.l.kehrer@gmail.com>2015-08-08 15:41:54 -0500
committerPaul Kehrer <paul.l.kehrer@gmail.com>2015-08-08 15:53:47 -0500
commitcc671824ad133df93bbf903ef2d363b54b5835a9 (patch)
treec15fe2d3cecead97b41d395e770a068b5c4ba2d5 /src
parent26ac47f1326fb4b8909d40ea0683eafcb9bd858e (diff)
downloadcryptography-cc671824ad133df93bbf903ef2d363b54b5835a9.tar.gz
cryptography-cc671824ad133df93bbf903ef2d363b54b5835a9.tar.bz2
cryptography-cc671824ad133df93bbf903ef2d363b54b5835a9.zip
address review comments
Diffstat (limited to 'src')
-rw-r--r--src/cryptography/x509.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/cryptography/x509.py b/src/cryptography/x509.py
index 3f306e3a..713e92a2 100644
--- a/src/cryptography/x509.py
+++ b/src/cryptography/x509.py
@@ -41,10 +41,10 @@ def _key_identifier_from_public_key(public_key):
spki, remaining = decoder.decode(
serialized, asn1Spec=_SubjectPublicKeyInfo()
)
+ assert not remaining
# the univ.BitString object is a tuple of bits. We need bytes and
# pyasn1 really doesn't want to give them to us. To get it we'll
# build an integer and convert that to bytes.
- assert not remaining
bits = 0
for bit in spki.getComponentByName("subjectPublicKey"):
bits = bits << 1 | bit