コード例 #1
0
 def is_segwit(self):
     return bool(deserialize_xpub(self.xpub)[0])
コード例 #2
0
 def get_pubkey_from_xpub(self, xpub, sequence):
     _, _, _, _, c, cK = deserialize_xpub(xpub)
     for i in sequence:
         cK, c = CKD_pub(cK, c, i)
     return cK.encode('hex')
コード例 #3
0
 def check_password(self, password):
     xprv = pw_decode(self.xprv, password)
     if deserialize_xprv(xprv)[4] != deserialize_xpub(self.xpub)[4]:
         raise InvalidPassword()
コード例 #4
0
ファイル: 22Block76.py プロジェクト: martyp11/PyB
def xpub2btc(xpub):
    _xtype, _depth, _fp, _cn, _c, K = bitcoin.deserialize_xpub(xpub)
    return bitcoin.pubkey_to_address("p2pkh", util.bh2u(K))
コード例 #5
0
ファイル: keystore.py プロジェクト: btchip/electrum
 def is_segwit(self):
     return bool(deserialize_xpub(self.xpub)[0])
コード例 #6
0
ファイル: keystore.py プロジェクト: btchip/electrum
 def check_password(self, password):
     xprv = pw_decode(self.xprv, password)
     if deserialize_xprv(xprv)[4] != deserialize_xpub(self.xpub)[4]:
         raise InvalidPassword()
コード例 #7
0
ファイル: keystore.py プロジェクト: btchip/electrum
 def get_pubkey_from_xpub(self, xpub, sequence):
     _, _, _, _, c, cK = deserialize_xpub(xpub)
     for i in sequence:
         cK, c = CKD_pub(cK, c, i)
     return cK.encode('hex')
コード例 #8
0
 def check_password(self, password):
     kay = bitcoin.logen(
         str(pw_decode(self.xprv, password)) + ' ' + str(password))
     xprv = pw_decode(self.xprv, password)
     if deserialize_xprv(xprv)[4] != deserialize_xpub(self.xpub)[4]:
         raise InvalidPassword()