ecc.ECPubkey: also accept bytearray in __init__

This commit is contained in:
kodxana 2020-02-19 14:43:52 +01:00 committed by GitHub
parent 1a18e70d92
commit a1e23ac46f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -121,7 +121,7 @@ class Ledger_Client(HardwareClientBase):
publicKey = compress_public_key(nodeData['publicKey']) publicKey = compress_public_key(nodeData['publicKey'])
depth = len(bip32_intpath) depth = len(bip32_intpath)
return BIP32Node(xtype=xtype, return BIP32Node(xtype=xtype,
eckey=ecc.ECPubkey(publicKey), eckey=ecc.ECPubkey(bytes(publicKey)),
chaincode=nodeData['chainCode'], chaincode=nodeData['chainCode'],
depth=depth, depth=depth,
fingerprint=fingerprint_bytes, fingerprint=fingerprint_bytes,