Browse Source

Test every numeric-accepting opcode for correct handling of the numeric minimal encoding rule

pull/145/head
Peter Todd 10 years ago
committed by Pieter Wuille
parent
commit
dfeec18b85
  1. 50
      src/test/data/script_invalid.json

50
src/test/data/script_invalid.json

@ -400,6 +400,56 @@ nSequences are max.
["1 IF 0x01 0x05 ENDIF 1", "", "MINIMALDATA", "evaluated non-minimal data"],
["1 IF 0x4c 0x03 0x222222 ENDIF 1", "", "MINIMALDATA", "evaluated non-minimal data"],
["Test every numeric-accepting opcode for correct handling of the numeric minimal encoding rule"],
["1 0x02 0x0000", "PICK DROP", "MINIMALDATA"],
["1 0x02 0x0000", "ROLL DROP 1", "MINIMALDATA"],
["0x02 0x0000", "1ADD DROP 1", "MINIMALDATA"],
["0x02 0x0000", "1SUB DROP 1", "MINIMALDATA"],
["0x02 0x0000", "NEGATE DROP 1", "MINIMALDATA"],
["0x02 0x0000", "ABS DROP 1", "MINIMALDATA"],
["0x02 0x0000", "NOT DROP 1", "MINIMALDATA"],
["0x02 0x0000", "0NOTEQUAL DROP 1", "MINIMALDATA"],
["0 0x02 0x0000", "ADD DROP 1", "MINIMALDATA"],
["0x02 0x0000 0", "ADD DROP 1", "MINIMALDATA"],
["0 0x02 0x0000", "SUB DROP 1", "MINIMALDATA"],
["0x02 0x0000 0", "SUB DROP 1", "MINIMALDATA"],
["0 0x02 0x0000", "BOOLAND DROP 1", "MINIMALDATA"],
["0x02 0x0000 0", "BOOLAND DROP 1", "MINIMALDATA"],
["0 0x02 0x0000", "BOOLOR DROP 1", "MINIMALDATA"],
["0x02 0x0000 0", "BOOLOR DROP 1", "MINIMALDATA"],
["0 0x02 0x0000", "NUMEQUAL DROP 1", "MINIMALDATA"],
["0x02 0x0000 1", "NUMEQUAL DROP 1", "MINIMALDATA"],
["0 0x02 0x0000", "NUMEQUALVERIFY 1", "MINIMALDATA"],
["0x02 0x0000 0", "NUMEQUALVERIFY 1", "MINIMALDATA"],
["0 0x02 0x0000", "NUMNOTEQUAL DROP 1", "MINIMALDATA"],
["0x02 0x0000 0", "NUMNOTEQUAL DROP 1", "MINIMALDATA"],
["0 0x02 0x0000", "LESSTHAN DROP 1", "MINIMALDATA"],
["0x02 0x0000 0", "LESSTHAN DROP 1", "MINIMALDATA"],
["0 0x02 0x0000", "GREATERTHAN DROP 1", "MINIMALDATA"],
["0x02 0x0000 0", "GREATERTHAN DROP 1", "MINIMALDATA"],
["0 0x02 0x0000", "LESSTHANOREQUAL DROP 1", "MINIMALDATA"],
["0x02 0x0000 0", "LESSTHANOREQUAL DROP 1", "MINIMALDATA"],
["0 0x02 0x0000", "GREATERTHANOREQUAL DROP 1", "MINIMALDATA"],
["0x02 0x0000 0", "GREATERTHANOREQUAL DROP 1", "MINIMALDATA"],
["0 0x02 0x0000", "MIN DROP 1", "MINIMALDATA"],
["0x02 0x0000 0", "MIN DROP 1", "MINIMALDATA"],
["0 0x02 0x0000", "MAX DROP 1", "MINIMALDATA"],
["0x02 0x0000 0", "MAX DROP 1", "MINIMALDATA"],
["0x02 0x0000 0 0", "WITHIN DROP 1", "MINIMALDATA"],
["0 0x02 0x0000 0", "WITHIN DROP 1", "MINIMALDATA"],
["0 0 0x02 0x0000", "WITHIN DROP 1", "MINIMALDATA"],
["0 0 0x02 0x0000", "CHECKMULTISIG DROP 1", "MINIMALDATA"],
["0 0x02 0x0000 0", "CHECKMULTISIG DROP 1", "MINIMALDATA"],
["0 0x02 0x0000 0 1", "CHECKMULTISIG DROP 1", "MINIMALDATA"],
["0 0 0x02 0x0000", "CHECKMULTISIGVERIFY 1", "MINIMALDATA"],
["0 0x02 0x0000 0", "CHECKMULTISIGVERIFY 1", "MINIMALDATA"],
[
"0x47 0x30440220304eff7556bba9560df47873275e64db45f3cd735998ce3f00d2e57b1bb5f31302205c0c9d14b8b80d43e2ac9b87532f1af6d8a3271262bc694ec4e14068392bb0a001",
"0x41 0x0479be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8 CHECKSIG",

Loading…
Cancel
Save