2

The before transaction is @ https://www.blocktrail.com/tBTC/tx/da58f6688b0727a7f1bf3eec899099bde1f18b9c7099f9d2c79556db238e623d

Its output script is "OP_HASH160 da1745e9b549bd0bfa1a569971c77eba30cd5a4b OP_EQUAL".

The current transaction is @ https://www.blocktrail.com/tBTC/tx/839b903b9f79c3372792ceb95917047c46d1b919ed1f6471f5a19d7c865ab32c?txinIdx=0

Its input script is "51".

I verified the transaction manually but it failed. Why the transaction was accepted and confirmed?

The evolved stack is as below. What's wrong? 628850cb844fe63c308c62afc8bc5351f1952a7f = RIPEMD160(SHA256(1)) enter image description here

1

The transaction is valid. This golang code gives the correct result.

You need to HASH160 51, not 1.

Additionally, make sure you run the hash on 0x51, not "51" or int(51).

  • Thank you for your answer, Raghav! I cannot access the golang code on github. Could you please update the url link? Thanks again. – J Doe Apr 27 '18 at 8:49
  • @JDoe That's odd. Seems to work for me. Here's the same code on pastebin – Raghav Sood Apr 27 '18 at 8:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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