|
|
@ -256,7 +256,7 @@ class Wallet: |
|
|
|
if item.get('txid') == txin['tx_hash'] and item.get('vout') == txin['index']: |
|
|
|
txin['raw_output_script'] = item['scriptPubKey'] |
|
|
|
txin['redeemScript'] = item.get('redeemScript') |
|
|
|
txin['electrumKeyID'] = item.get('electrumKeyID') |
|
|
|
txin['KeyID'] = item.get('KeyID') |
|
|
|
break |
|
|
|
else: |
|
|
|
for item in unspent_coins: |
|
|
@ -268,8 +268,9 @@ class Wallet: |
|
|
|
raise |
|
|
|
|
|
|
|
# find the address: |
|
|
|
if txin.get('electrumKeyID'): |
|
|
|
account, sequence = txin.get('electrumKeyID') |
|
|
|
if txin.get('KeyID'): |
|
|
|
account, name, sequence = txin.get('KeyID') |
|
|
|
if name != 'Electrum': continue |
|
|
|
sec = self.sequences[account].get_private_key(sequence, seed) |
|
|
|
addr = self.sequences[account].get_address(sequence) |
|
|
|
txin['address'] = addr |
|
|
@ -771,7 +772,7 @@ class Wallet: |
|
|
|
pk_addresses.append(address) |
|
|
|
continue |
|
|
|
account, sequence = self.get_address_index(address) |
|
|
|
txin['electrumKeyID'] = (account, sequence) # used by the server to find the key |
|
|
|
txin['KeyID'] = (account, 'Electrum', sequence) # used by the server to find the key |
|
|
|
pk_addr, redeemScript = self.sequences[account].get_input_info(sequence) |
|
|
|
if redeemScript: txin['redeemScript'] = redeemScript |
|
|
|
pk_addresses.append(pk_addr) |
|
|
|