Open afk11 opened 4 years ago
Decode a transaction https://github.com/Bit-Wasp/bitcoin-php/blob/1.0/examples/doc/tx/005_create_tx_from_hex.php Sign a P2SH multisig transaction. There are examples of other address types. Just delete the part that builds the spend transaction, and call TransactionFactory::fromHex instead. https://github.com/Bit-Wasp/bitcoin-php/blob/1.0/examples/tx.spend.p2sh.multisig.php
It still does not work, I'm using the following scripts from the examples folder: transactionBuilder.php tx.sighash.single.bug.php
I'm uniting both of them to build the Transaction and sign in.
But it gives me an error: Uncaught BitWasp\Bitcoin\Exceptions\ScriptQualificationError: Invalid script signature - must be PUSHONLY.
Unfortunately I can't debug your code without seeing it. Based on the error, you probably put the redeem or output script in the scriptSig instead of pushing it..
Your assumption was correct, indeed. It worked.
Having the raw transaction (non-signed), how can I sign it using bitcoin-php version 1.0?
Originally posted by @Gwinest in https://github.com/Bit-Wasp/bitcoin-php/issues/166#issuecomment-588584875