We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
OP_ADD appears to treat stack items as hex values, as expected:
0x0a 0x06 OP_ADD 0x10 OP_EQUAL
http://www.crmarsh.com/script-playground/#0x0a%200x06%20OP_ADD%200x10%20OP_EQUAL
However, it looks like OP_SHA256 (and OP_RIPEMD160) treats stack items as text. I expect this to fail (but it passes):
0x0a OP_SHA256 0xca978112ca1bbdcafac231b39a23dc4da786eff8147c4e72b9807785afee48bb OP_EQUAL
http://www.crmarsh.com/script-playground/#0x0a%20OP_SHA256%200xca978112ca1bbdcafac231b39a23dc4da786eff8147c4e72b9807785afee48bb%20OP_EQUAL
and this to pass (but it fails):
0x61 OP_SHA256 0xca978112ca1bbdcafac231b39a23dc4da786eff8147c4e72b9807785afee48bb OP_EQUAL
http://www.crmarsh.com/script-playground/#0x61%20OP_SHA256%200xca978112ca1bbdcafac231b39a23dc4da786eff8147c4e72b9807785afee48bb%20OP_EQUAL
Ideas?
The text was updated successfully, but these errors were encountered:
I suggest using bitcore's Script library. It is better maintained. https://bitcore.io/api/lib/script
You can play with it here: https://bitcore.io/playground
Sorry, something went wrong.
No branches or pull requests
OP_ADD appears to treat stack items as hex values, as expected:
http://www.crmarsh.com/script-playground/#0x0a%200x06%20OP_ADD%200x10%20OP_EQUAL
However, it looks like OP_SHA256 (and OP_RIPEMD160) treats stack items as text. I expect this to fail (but it passes):
http://www.crmarsh.com/script-playground/#0x0a%20OP_SHA256%200xca978112ca1bbdcafac231b39a23dc4da786eff8147c4e72b9807785afee48bb%20OP_EQUAL
and this to pass (but it fails):
http://www.crmarsh.com/script-playground/#0x61%20OP_SHA256%200xca978112ca1bbdcafac231b39a23dc4da786eff8147c4e72b9807785afee48bb%20OP_EQUAL
Ideas?
The text was updated successfully, but these errors were encountered: