fix issue #1713
This commit is contained in:
@@ -30,7 +30,7 @@
|
|||||||
|
|
||||||
import binascii
|
import binascii
|
||||||
|
|
||||||
from x509 import ASN1_Node
|
from x509 import ASN1_Node, bytestr_to_int, decode_OID
|
||||||
|
|
||||||
|
|
||||||
def a2b_base64(s):
|
def a2b_base64(s):
|
||||||
@@ -173,6 +173,7 @@ def bytesToNumber(s):
|
|||||||
|
|
||||||
|
|
||||||
def _parseASN1PrivateKey(s):
|
def _parseASN1PrivateKey(s):
|
||||||
|
s = ASN1_Node(s)
|
||||||
root = s.root()
|
root = s.root()
|
||||||
version_node = s.first_child(root)
|
version_node = s.first_child(root)
|
||||||
version = bytestr_to_int(s.get_value_of_type(version_node, 'INTEGER'))
|
version = bytestr_to_int(s.get_value_of_type(version_node, 'INTEGER'))
|
||||||
|
|||||||
Reference in New Issue
Block a user