I'm trying to understand how Script validates transactions.

I have taken this transaction as an example 55e5bbdba33050bbe6584e896b4a20575cf3fe3f29114467f17f67f6b172eb73

When showing the scripts, we can see as input

ScriptSig: PUSHDATA(72)[3045022100c70904b2925a6822fd3dc2d236bcba1fa1518fdfdadbda8f25a89a339879c82a02200bd7ca7d502d46ebc6fbc97f51af3d0ab4f290d73931ada9abb76fb1b6d3b55b01] 

And output :

DUP HASH160 PUSHDATA(20)[57d713220076f8298b54e9eea84d2e1dde62e4a1] EQUALVERIFY CHECKSIG

So, from what I understood, if these script bits are run one after another, the result should be true (please correct me if I'm already mistaken at that point).

I have used an online Script debugger but these bits did not return a success.

Has anyone an explanation on why I couldn't get this right ?

  • taking the pubkey hash from the previous tx (6fe066d1be6359dba98e7f00f3f45707e0bd07ad), I can see the stack pushes the sig (3045022100c70904b...), then the pubkey (043fd05d2490b2b...). On top goes "OP_DUP", and there are two pubkeys. Good. This duplicated pubkey is hashed (6fe066d1be6359...), and OP_EQUALVERIFY'd. Good, they are the same. The user "is allowed" to spend the funds... Then only sig and pubkey remain, and OP_CHECKSIG returns "NULL" - so a failed stack. I did the same with one of my "old" tx, and it failed as well... At a different step (OP_HASH160) - amybe contact the author... Commented Nov 29, 2017 at 9:17
  • when you choose the "empty" button, and provide only sig and pubkey, it verifies to "RESULT OK". But then again, change the keys or hashes (even giving a non-hex char), it still returns ok... there might be s.th. going wrong with the page, or I'm missing something terribly. Commented Nov 29, 2017 at 9:28

1 Answer 1


You are not supposed to be using the output scripts of the outputs created in the transaction but rather the output script of the output that is being spent. What you are using is the output script of the output in that transaction.

Rather you should click the output link next to the input and get the output script from the referenced output that the link takes you to.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.