mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-11 22:50:59 +01:00
Construct and use PrecomputedTransactionData in PSBT signing
This commit is contained in:
@@ -1655,6 +1655,7 @@ static RPCHelpMan utxoupdatepsbt()
|
||||
}
|
||||
|
||||
// Fill the inputs
|
||||
const PrecomputedTransactionData txdata = PrecomputePSBTData(psbtx);
|
||||
for (unsigned int i = 0; i < psbtx.tx->vin.size(); ++i) {
|
||||
PSBTInput& input = psbtx.inputs.at(i);
|
||||
|
||||
@@ -1671,7 +1672,7 @@ static RPCHelpMan utxoupdatepsbt()
|
||||
// Update script/keypath information using descriptor data.
|
||||
// Note that SignPSBTInput does a lot more than just constructing ECDSA signatures
|
||||
// we don't actually care about those here, in fact.
|
||||
SignPSBTInput(public_provider, psbtx, i, /* sighash_type */ 1);
|
||||
SignPSBTInput(public_provider, psbtx, i, &txdata, /* sighash_type */ 1);
|
||||
}
|
||||
|
||||
// Update script/keypath information using descriptor data.
|
||||
|
||||
Reference in New Issue
Block a user