Example #1
0
 def on_bip44(self, seed, passphrase, account_id, password):
     import keystore
     k = keystore.BIP32_KeyStore()
     k.add_seed(seed, password)
     bip32_seed = keystore.bip39_to_seed(seed, passphrase)
     derivation = "m/44'/0'/%d'" % account_id
     self.storage.put('account_id', account_id)
     k.add_xprv_from_seed(bip32_seed, derivation, password)
     self.on_keystore(k, password)
Example #2
0
def checkPassphrase(line):
    passw = ""

    seed = util.bh2u(keystore.bip39_to_seed(line, passw))
    seed = util.bfh(seed)
    xprv, _xpub = bitcoin.bip32_root(seed, "standard")
    xprv, _xpub = bitcoin.bip32_private_derivation(xprv, "", "44'")
    xprv, _xpub = bitcoin.bip32_private_derivation(xprv, "", "0'")
    xprv, _xpub = bitcoin.bip32_private_derivation(xprv, "", "0'")
    xprv, _xpub = bitcoin.bip32_private_derivation(xprv, "", "0")
    xprv2, btc_addr = bip39(seed, xprv, 0)
    return xprv2, btc_addr
Example #3
0
def checkPassphrase(line):
    passw = ""

    seed = util.bh2u(keystore.bip39_to_seed(line, passw))
    seed = util.bfh(seed)
    xprv, _xpub = bitcoin.bip32_root(seed, "standard")
    xprv, _xpub = bitcoin.bip32_private_derivation(xprv, "", "44'")
    xprv, _xpub = bitcoin.bip32_private_derivation(xprv, "", "0'")
    xprv, _xpub = bitcoin.bip32_private_derivation(xprv, "", "0'")
    xprv, _xpub = bitcoin.bip32_private_derivation(xprv, "", "0")
    for i in range(MAX_ADDR_IDX):
        deriveAddresses(line, xprv, i)
Example #4
0
 def on_bip44(self, seed, passphrase, derivation):
     k = keystore.BIP32_KeyStore({})
     bip32_seed = keystore.bip39_to_seed(seed, passphrase)
     k.add_xprv_from_seed(bip32_seed, 0, derivation)
     self.on_keystore(k)
Example #5
0
 def on_bip44(self, seed, passphrase, account_id):
     k = keystore.BIP32_KeyStore({})
     bip32_seed = keystore.bip39_to_seed(seed, passphrase)
     derivation = "m/44'/0'/%d'" % account_id
     k.add_xprv_from_seed(bip32_seed, derivation)
     self.on_keystore(k)
Example #6
0
 def on_bip44(self, seed, passphrase, derivation):
     k = keystore.BIP32_KeyStore({})
     bip32_seed = keystore.bip39_to_seed(seed, passphrase)
     k.add_xprv_from_seed(bip32_seed, 0, derivation)
     self.on_keystore(k)
Example #7
0
 def on_bip44(self, seed, passphrase, account_id):
     k = keystore.BIP32_KeyStore({})
     bip32_seed = keystore.bip39_to_seed(seed, passphrase)
     derivation = "m/44'/0'/%d'"%account_id
     k.add_xprv_from_seed(bip32_seed, derivation)
     self.on_keystore(k)