File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed
Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change 1919from pymdoccbor .tools import shuffle_dict
2020from cryptography import x509
2121from cryptography .hazmat .primitives import serialization
22+ from cryptography .x509 import Certificate
2223
2324
2425from cbor_diag import *
@@ -223,10 +224,10 @@ def sign(
223224 _err_msg = f"Certificate at { self .cert_path } could not be loaded as DER"
224225 logger .error (_err_msg )
225226
226- if _parsed_cert :
227- cert = _parsed_cert
228- else :
229- raise Exception (f"Certificate at { self .cert_path } failed parse" )
227+ if _parsed_cert :
228+ cert = _parsed_cert
229+ else :
230+ raise Exception (f"Certificate at { self .cert_path } failed parse" )
230231 _cert = cert .public_bytes (getattr (serialization .Encoding , "DER" ))
231232 else :
232233 _cert = self .selfsigned_x509cert ()
You can’t perform that action at this time.
0 commit comments