Skip to content

Commit 29bed7e

Browse files
committed
Merge #310: Fix finalizer check for sh(wpkh)
983b889 Fix finalizer check for sh(wpkh) (sanket1729) Pull request description: We should check the witness script hashes to the redeem script in the nested sh wsh case. Not the script pubkey Caught up integration tests ACKs for top commit: apoelstra: ACK 983b889 Tree-SHA512: 0c774eae86b05eae07137a47bc8ae71e252a118aeaf3b5ffb7eac547da1bbe147856af392c995cf1f5dae1d65f4d27fb64ad20eea48d2de454e01f48ed968e64
2 parents 6cd1fb6 + 983b889 commit 29bed7e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/psbt/finalizer.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -236,7 +236,7 @@ fn get_descriptor(psbt: &Psbt, index: usize) -> Result<Descriptor<PublicKey>, In
236236
let pk = bitcoin::PublicKey::new(pk);
237237
let addr = bitcoin::Address::p2wpkh(&pk, bitcoin::Network::Bitcoin)
238238
.expect("Address corresponding to valid pubkey");
239-
*script_pubkey == addr.script_pubkey()
239+
*redeem_script == addr.script_pubkey()
240240
})
241241
.next();
242242
match partial_sig_contains_pk {

0 commit comments

Comments
 (0)