|
|
@ -351,15 +351,18 @@ class KeepKeyPlugin(HW_PluginBase): |
|
|
|
assert isinstance(tx, PartialTransaction) |
|
|
|
assert isinstance(txin, PartialTxInput) |
|
|
|
assert keystore |
|
|
|
xpubs_and_deriv_suffixes = get_xpubs_and_der_suffixes_from_txinout(tx, txin) |
|
|
|
multisig = self._make_multisig(txin.num_sig, xpubs_and_deriv_suffixes) |
|
|
|
if len(txin.pubkeys) > 1: |
|
|
|
xpubs_and_deriv_suffixes = get_xpubs_and_der_suffixes_from_txinout(tx, txin) |
|
|
|
multisig = self._make_multisig(txin.num_sig, xpubs_and_deriv_suffixes) |
|
|
|
else: |
|
|
|
multisig = None |
|
|
|
script_type = self.get_keepkey_input_script_type(txin.script_type) |
|
|
|
txinputtype = self.types.TxInputType( |
|
|
|
script_type=script_type, |
|
|
|
multisig=multisig) |
|
|
|
my_pubkey, full_path = keystore.find_my_pubkey_in_txinout(txin) |
|
|
|
if full_path: |
|
|
|
txinputtype.address_n = full_path |
|
|
|
txinputtype.address_n.extend(full_path) |
|
|
|
|
|
|
|
prev_hash = txin.prevout.txid |
|
|
|
prev_index = txin.prevout.out_idx |
|
|
@ -387,12 +390,15 @@ class KeepKeyPlugin(HW_PluginBase): |
|
|
|
signatures=[b''] * len(pubkeys), |
|
|
|
m=m) |
|
|
|
|
|
|
|
def tx_outputs(self, tx: PartialTransaction, *, keystore: 'KeepKey_KeyStore' = None): |
|
|
|
def tx_outputs(self, tx: PartialTransaction, *, keystore: 'KeepKey_KeyStore'): |
|
|
|
|
|
|
|
def create_output_by_derivation(): |
|
|
|
script_type = self.get_keepkey_output_script_type(txout.script_type) |
|
|
|
xpubs_and_deriv_suffixes = get_xpubs_and_der_suffixes_from_txinout(tx, txout) |
|
|
|
multisig = self._make_multisig(txout.num_sig, xpubs_and_deriv_suffixes) |
|
|
|
if len(txout.pubkeys) > 1: |
|
|
|
xpubs_and_deriv_suffixes = get_xpubs_and_der_suffixes_from_txinout(tx, txout) |
|
|
|
multisig = self._make_multisig(txout.num_sig, xpubs_and_deriv_suffixes) |
|
|
|
else: |
|
|
|
multisig = None |
|
|
|
my_pubkey, full_path = keystore.find_my_pubkey_in_txinout(txout) |
|
|
|
assert full_path |
|
|
|
txoutputtype = self.types.TxOutputType( |
|
|
|