Because in my understanding I may provide a signature to unlock a txo
and someone uses my signature to change the locking scripts of those
Taking a "P2PKH tx", the unlockscript requires some operations to be executed while spending a tx:
I have three scenarios here, when changing parts of the script fields:
a miner changes the part with a new signature and pubkey. Assuming the block raelly gets "through", the spender of the funds has a problem, cause his would not match to the hash of the anymore.
2.) change only the
a miner changes only the part with a new signature. Now the spender's would match the hash of the . However the last command
<OP_CHECKSIG> would check the remaining parts on the stack (
<new sig><pubkey>), and this would (obviously) fail.
3.) change the pubkey script
when anything in the pubkey script is changed, then the signature process will fail. During creat
ion of the signed transaction, the sigscipt area is filled with the pubkey script, and then signe
d. Later on, before transmitting the tx, the sciptsig area is replaced with
So when the block would be propagated to other nodes, they would verify this block and it's tx in
side, and discover a signature mismatch.
Pieter explained details here of the scriptsig here:
What are the parts of a Bitcoin Transaction "Input" script?
and two references that further help to understand:
2) Andreas' book "Mastering Bitcoin", 2nd Edition, page 135ff