Open gregdhill opened 3 years ago
The redeemScript you have set as input in signP2SHTransaction is wrong. You have to use the redeemScript of the input, not the one for the output. See more details here: https://github.com/bitcoinjs/bitcoinjs-lib/issues/1517#issuecomment-1064367562
Firmware: 1.6.0 Bitcoin Test (BTC): Version 1.4.2
Packages:
@ledgerhq/hw-transport-node-hid
@ledgerhq/hw-app-btc
Summary
Signing a SegWit (P2WPKH-in-P2SH) input produces an invalid signature when compared with the output from bitcoinjs-lib when using the node client.
Example