BTC

Description

problem description

Solution

We visit the attached website and find details of a transaction transferring 161500.99966998 BTC between two entities.

The most significant detail on the page is the following sequence which is marked as a "Pkscript":

7401248801017901ffa101018801027901ffa101018801037901ffa101018801047901ffa101018801057901ffa101018801067901ffa101018801077901ffa101018801087901ffa101018801097901ffa1010188010a7901ffa1010188010b7901ffa1010188010c7901ffa1010188010d7901ffa1010188010e7901ffa1010188010f7901ffa101018801107901ffa101018801117901ffa101018801127901ffa101018801137901ffa101018801147901ffa101018801157901ffa101018801167901ffa101018801177901ffa101018801187901ffa101018801197901ffa1010188011a7901ffa1010188011b7901ffa1010188011c7901ffa1010188011d7901ffa1010188011e7901ffa1010188011f7901ffa101018801207901ffa101018801217901ffa101018801227901ffa101018801237901ffa101018801247901ffa10101888c017c88a820e29c9c180c6279b0b02abd6a1801c7c04082cf486ec027aa13515e4f3884bb6b88018a8601bb88739301de880102798b01608876769393019688757601cc8763006a6701d58601bb8868aa20bed5fe7c6a43a11e4d7dbe4293f6aa2eeb65025b5f78a518fdd7447ed2ccc55e882627446f6d696e696f6e2720697320616e20696d706f7274616e7420646f63756d656e74617279a7143a4e3aedaf36ced1a17af38a73fbc0cda118220e8701ff6d7601609f93016088a820da4ea2a5506f2693eae190d9360a1f31793c98a1adade51d93533a6f520ace1c887601009e697601019e697601029e697601039e697601049e697601059e697601069e697601079e697601089e697601099e6976010a9e6976010b9e6976010c9e6976010d9e6976010e9e6976010f9e697601109e697601119e697601129e697601139e697601149e697601159e697601169e697601179e697601189e697601199e6976011a9e6976011b9e6976011c9e6976011d9e6976011e9e6976011f9e697601209e697601219e697601229e697601239e697601249e697601259e697601269e697601279e697601289e697601299e6976012a9e6976012b9e6976012c9e6976012d9e6976012e9e6976012f9e697601309e697601319e697601329e697601339e697601349e697601359e697601369e697601379e697601389e697601399e6976013a9e6976013b9e6976013c9e6976013d9e6976013e9e6976013f9e697601409e697601419e697601429e697601439e697601449e697601459e697601469e697601479e697601489e697601499e6976014a9e6976014b9e6976014c9e6976014d9e6976014e9e6976014f9e697601509e697601519e697601529e697601539e697601549e697601559e697601569e697601579e697601589e697601599e6976015a9e6976015b9e6976015c9e6976015d9e6976015e9e6976015f9e697601609e697601619e697601629e697601639e697601649e697601659e697601669e697601679e697601689e697601699e6976016a9e6976016b9e6976016c9e6976016d9e6976016e9e6976016f9e697601709e697601719e697601729e697601739e697601759e697601769e697601779e697601789e697601799e6976017a9e6976017b9e6976017c9e6976017d9e6976017e9e6976017f9e697601809e697601819e697601829e697601839e697601849e697601859e697601869e697601879e697601889e697601899e6976018a9e6976018b9e6976018c9e6976018d9e6976018e9e6976018f9e697601909e697601919e697601929e697601939e697601949e697601959e697601969e697601979e697601989e697601999e6976019a9e6976019b9e6976019c9e6976019d9e6976019e9e6976019f9e697601a09e697601a19e697601a29e697601a39e697601a49e697601a59e697601a69e697601a79e697601a89e697601a99e697601aa9e697601ab9e697601ac9e697601ad9e697601ae9e697601af9e697601b09e697601b19e697601b29e697601b39e697601b49e697601b59e697601b69e697601b79e697601b89e697601b99e697601ba9e697601bb9e697601bc9e697601bd9e697601be9e697601bf9e697601c09e697601c19e697601c29e697601c39e697601c49e697601c59e697601c69e697601c79e697601c89e697601c99e697601ca9e697601cb9e697601cc9e697601cd9e697601ce9e697601cf9e697601d09e697601d19e697601d29e697601d39e697601d49e697601d59e697601d69e697601d79e697601d89e697601d99e697601da9e697601db9e697601dc9e697601dd9e697601de9e697601df9e697601e09e697601e19e697601e29e697601e39e697601e49e697601e59e697601e69e697601e79e697601e89e697601e99e697601ea9e697601eb9e697601ec9e697601ed9e697601ee9e697601ef9e697601f09e697601f19e697601f29e697601f39e697601f49e697601f59e697601f69e697601f79e697601f89e697601f99e697601fa9e697601fb9e697601fc9e697601fd9e697601fe9e69758c016188a82006cdede198bc96a594f1685fcdc2f7b3f39a454ac97d700a1c63b2bc02cd75e18801cf8601bb88739301d0880102798b0176887676939302013588757601cc8763006a67018b8601bb8868aa20800ae3457a8da20b0d47089c53715054313b4974c28c6af1fefbde1fcb0fdf54887601609f93016088a820a68b412c4282555f15546cf6e1fc42893b7e07f271557ceb021821098dd66c1b888c016888a82006cdede198bc96a594f1685fcdc2f7b3f39a454ac97d700a1c63b2bc02cd75e18801d38601bb887393016a880102798b0158887676939302013b88757601cc8763006a6701e48601bb88687601329f93013288a820925a7bf1cc6e3b9a91aba051665a28fbc2fe5261cb6ffaaaf1decb7282252b2288015488014e88014588015488014e88014988

Bitcoin uses a scripting system for transactions. Forth-like, Script is simple, stack-based, and processed from left to right. It is intentionally not Turing-complete, with no loops. A script is essentially a list of instructions recorded with each transaction that describe how the next person wanting to spend the Bitcoins being transferred can gain access to them. (Source)

If we take the pkscript and paste it in the "Assembly" tab of this online BTC IDE, we get the following script:

Click to expand
OP_DEPTH 24 OP_EQUALVERIFY 01 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 02 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 03 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 04 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 05 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 06 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 07 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 08 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 09 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 0a OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 0b OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 0c OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 0d OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 0e OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 0f OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 10 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 11 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 12 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 13 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 14 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 15 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 16 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 17 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 18 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 19 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 1a OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 1b OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 1c OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 1d OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 1e OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 1f OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 20 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 21 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 22 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 23 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 24 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY OP_1SUB 7c OP_EQUALVERIFY OP_SHA256 e29c9c180c6279b0b02abd6a1801c7c04082cf486ec027aa13515e4f3884bb6b OP_EQUALVERIFY 8a OP_XOR bb OP_EQUALVERIFY OP_IFDUP OP_ADD de OP_EQUALVERIFY 02 OP_PICK OP_1ADD 60 OP_EQUALVERIFY OP_DUP OP_DUP OP_ADD OP_ADD 96 OP_EQUALVERIFY OP_DROP OP_DUP cc OP_EQUAL OP_IF OP_FALSE OP_RETURN OP_ELSE d5 OP_XOR bb OP_EQUALVERIFY OP_ENDIF OP_HASH256 bed5fe7c6a43a11e4d7dbe4293f6aa2eeb65025b5f78a518fdd7447ed2ccc55e OP_EQUALVERIFY 27446f6d696e696f6e2720697320616e20696d706f7274616e7420646f63756d656e74617279 OP_SHA1 3a4e3aedaf36ced1a17af38a73fbc0cda118220e OP_EQUAL ff OP_2DROP OP_DUP 60 OP_LESSTHAN OP_ADD 60 OP_EQUALVERIFY OP_SHA256 da4ea2a5506f2693eae190d9360a1f31793c98a1adade51d93533a6f520ace1c OP_EQUALVERIFY OP_DUP 00 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 01 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 02 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 03 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 04 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 05 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 06 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 07 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 08 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 09 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 0a OP_NUMNOTEQUAL OP_VERIFY OP_DUP 0b OP_NUMNOTEQUAL OP_VERIFY OP_DUP 0c OP_NUMNOTEQUAL OP_VERIFY OP_DUP 0d OP_NUMNOTEQUAL OP_VERIFY OP_DUP 0e OP_NUMNOTEQUAL OP_VERIFY OP_DUP 0f OP_NUMNOTEQUAL OP_VERIFY OP_DUP 10 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 11 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 12 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 13 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 14 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 15 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 16 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 17 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 18 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 19 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 1a OP_NUMNOTEQUAL OP_VERIFY OP_DUP 1b OP_NUMNOTEQUAL OP_VERIFY OP_DUP 1c OP_NUMNOTEQUAL OP_VERIFY OP_DUP 1d OP_NUMNOTEQUAL OP_VERIFY OP_DUP 1e OP_NUMNOTEQUAL OP_VERIFY OP_DUP 1f OP_NUMNOTEQUAL OP_VERIFY OP_DUP 20 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 21 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 22 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 23 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 24 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 25 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 26 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 27 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 28 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 29 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 2a OP_NUMNOTEQUAL OP_VERIFY OP_DUP 2b OP_NUMNOTEQUAL OP_VERIFY OP_DUP 2c OP_NUMNOTEQUAL OP_VERIFY OP_DUP 2d OP_NUMNOTEQUAL OP_VERIFY OP_DUP 2e OP_NUMNOTEQUAL OP_VERIFY OP_DUP 2f OP_NUMNOTEQUAL OP_VERIFY OP_DUP 30 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 31 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 32 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 33 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 34 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 35 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 36 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 37 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 38 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 39 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 3a OP_NUMNOTEQUAL OP_VERIFY OP_DUP 3b OP_NUMNOTEQUAL OP_VERIFY OP_DUP 3c OP_NUMNOTEQUAL OP_VERIFY OP_DUP 3d OP_NUMNOTEQUAL OP_VERIFY OP_DUP 3e OP_NUMNOTEQUAL OP_VERIFY OP_DUP 3f OP_NUMNOTEQUAL OP_VERIFY OP_DUP 40 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 41 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 42 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 43 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 44 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 45 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 46 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 47 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 48 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 49 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 4a OP_NUMNOTEQUAL OP_VERIFY OP_DUP 4b OP_NUMNOTEQUAL OP_VERIFY OP_DUP 4c OP_NUMNOTEQUAL OP_VERIFY OP_DUP 4d OP_NUMNOTEQUAL OP_VERIFY OP_DUP 4e OP_NUMNOTEQUAL OP_VERIFY OP_DUP 4f OP_NUMNOTEQUAL OP_VERIFY OP_DUP 50 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 51 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 52 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 53 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 54 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 55 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 56 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 57 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 58 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 59 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 5a OP_NUMNOTEQUAL OP_VERIFY OP_DUP 5b OP_NUMNOTEQUAL OP_VERIFY OP_DUP 5c OP_NUMNOTEQUAL OP_VERIFY OP_DUP 5d OP_NUMNOTEQUAL OP_VERIFY OP_DUP 5e OP_NUMNOTEQUAL OP_VERIFY OP_DUP 5f OP_NUMNOTEQUAL OP_VERIFY OP_DUP 60 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 61 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 62 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 63 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 64 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 65 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 66 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 67 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 68 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 69 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 6a OP_NUMNOTEQUAL OP_VERIFY OP_DUP 6b OP_NUMNOTEQUAL OP_VERIFY OP_DUP 6c OP_NUMNOTEQUAL OP_VERIFY OP_DUP 6d OP_NUMNOTEQUAL OP_VERIFY OP_DUP 6e OP_NUMNOTEQUAL OP_VERIFY OP_DUP 6f OP_NUMNOTEQUAL OP_VERIFY OP_DUP 70 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 71 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 72 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 73 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 75 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 76 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 77 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 78 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 79 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 7a OP_NUMNOTEQUAL OP_VERIFY OP_DUP 7b OP_NUMNOTEQUAL OP_VERIFY OP_DUP 7c OP_NUMNOTEQUAL OP_VERIFY OP_DUP 7d OP_NUMNOTEQUAL OP_VERIFY OP_DUP 7e OP_NUMNOTEQUAL OP_VERIFY OP_DUP 7f OP_NUMNOTEQUAL OP_VERIFY OP_DUP 80 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 81 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 82 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 83 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 84 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 85 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 86 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 87 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 88 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 89 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 8a OP_NUMNOTEQUAL OP_VERIFY OP_DUP 8b OP_NUMNOTEQUAL OP_VERIFY OP_DUP 8c OP_NUMNOTEQUAL OP_VERIFY OP_DUP 8d OP_NUMNOTEQUAL OP_VERIFY OP_DUP 8e OP_NUMNOTEQUAL OP_VERIFY OP_DUP 8f OP_NUMNOTEQUAL OP_VERIFY OP_DUP 90 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 91 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 92 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 93 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 94 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 95 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 96 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 97 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 98 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 99 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 9a OP_NUMNOTEQUAL OP_VERIFY OP_DUP 9b OP_NUMNOTEQUAL OP_VERIFY OP_DUP 9c OP_NUMNOTEQUAL OP_VERIFY OP_DUP 9d OP_NUMNOTEQUAL OP_VERIFY OP_DUP 9e OP_NUMNOTEQUAL OP_VERIFY OP_DUP 9f OP_NUMNOTEQUAL OP_VERIFY OP_DUP a0 OP_NUMNOTEQUAL OP_VERIFY OP_DUP a1 OP_NUMNOTEQUAL OP_VERIFY OP_DUP a2 OP_NUMNOTEQUAL OP_VERIFY OP_DUP a3 OP_NUMNOTEQUAL OP_VERIFY OP_DUP a4 OP_NUMNOTEQUAL OP_VERIFY OP_DUP a5 OP_NUMNOTEQUAL OP_VERIFY OP_DUP a6 OP_NUMNOTEQUAL OP_VERIFY OP_DUP a7 OP_NUMNOTEQUAL OP_VERIFY OP_DUP a8 OP_NUMNOTEQUAL OP_VERIFY OP_DUP a9 OP_NUMNOTEQUAL OP_VERIFY OP_DUP aa OP_NUMNOTEQUAL OP_VERIFY OP_DUP ab OP_NUMNOTEQUAL OP_VERIFY OP_DUP ac OP_NUMNOTEQUAL OP_VERIFY OP_DUP ad OP_NUMNOTEQUAL OP_VERIFY OP_DUP ae OP_NUMNOTEQUAL OP_VERIFY OP_DUP af OP_NUMNOTEQUAL OP_VERIFY OP_DUP b0 OP_NUMNOTEQUAL OP_VERIFY OP_DUP b1 OP_NUMNOTEQUAL OP_VERIFY OP_DUP b2 OP_NUMNOTEQUAL OP_VERIFY OP_DUP b3 OP_NUMNOTEQUAL OP_VERIFY OP_DUP b4 OP_NUMNOTEQUAL OP_VERIFY OP_DUP b5 OP_NUMNOTEQUAL OP_VERIFY OP_DUP b6 OP_NUMNOTEQUAL OP_VERIFY OP_DUP b7 OP_NUMNOTEQUAL OP_VERIFY OP_DUP b8 OP_NUMNOTEQUAL OP_VERIFY OP_DUP b9 OP_NUMNOTEQUAL OP_VERIFY OP_DUP ba OP_NUMNOTEQUAL OP_VERIFY OP_DUP bb OP_NUMNOTEQUAL OP_VERIFY OP_DUP bc OP_NUMNOTEQUAL OP_VERIFY OP_DUP bd OP_NUMNOTEQUAL OP_VERIFY OP_DUP be OP_NUMNOTEQUAL OP_VERIFY OP_DUP bf OP_NUMNOTEQUAL OP_VERIFY OP_DUP c0 OP_NUMNOTEQUAL OP_VERIFY OP_DUP c1 OP_NUMNOTEQUAL OP_VERIFY OP_DUP c2 OP_NUMNOTEQUAL OP_VERIFY OP_DUP c3 OP_NUMNOTEQUAL OP_VERIFY OP_DUP c4 OP_NUMNOTEQUAL OP_VERIFY OP_DUP c5 OP_NUMNOTEQUAL OP_VERIFY OP_DUP c6 OP_NUMNOTEQUAL OP_VERIFY OP_DUP c7 OP_NUMNOTEQUAL OP_VERIFY OP_DUP c8 OP_NUMNOTEQUAL OP_VERIFY OP_DUP c9 OP_NUMNOTEQUAL OP_VERIFY OP_DUP ca OP_NUMNOTEQUAL OP_VERIFY OP_DUP cb OP_NUMNOTEQUAL OP_VERIFY OP_DUP cc OP_NUMNOTEQUAL OP_VERIFY OP_DUP cd OP_NUMNOTEQUAL OP_VERIFY OP_DUP ce OP_NUMNOTEQUAL OP_VERIFY OP_DUP cf OP_NUMNOTEQUAL OP_VERIFY OP_DUP d0 OP_NUMNOTEQUAL OP_VERIFY OP_DUP d1 OP_NUMNOTEQUAL OP_VERIFY OP_DUP d2 OP_NUMNOTEQUAL OP_VERIFY OP_DUP d3 OP_NUMNOTEQUAL OP_VERIFY OP_DUP d4 OP_NUMNOTEQUAL OP_VERIFY OP_DUP d5 OP_NUMNOTEQUAL OP_VERIFY OP_DUP d6 OP_NUMNOTEQUAL OP_VERIFY OP_DUP d7 OP_NUMNOTEQUAL OP_VERIFY OP_DUP d8 OP_NUMNOTEQUAL OP_VERIFY OP_DUP d9 OP_NUMNOTEQUAL OP_VERIFY OP_DUP da OP_NUMNOTEQUAL OP_VERIFY OP_DUP db OP_NUMNOTEQUAL OP_VERIFY OP_DUP dc OP_NUMNOTEQUAL OP_VERIFY OP_DUP dd OP_NUMNOTEQUAL OP_VERIFY OP_DUP de OP_NUMNOTEQUAL OP_VERIFY OP_DUP df OP_NUMNOTEQUAL OP_VERIFY OP_DUP e0 OP_NUMNOTEQUAL OP_VERIFY OP_DUP e1 OP_NUMNOTEQUAL OP_VERIFY OP_DUP e2 OP_NUMNOTEQUAL OP_VERIFY OP_DUP e3 OP_NUMNOTEQUAL OP_VERIFY OP_DUP e4 OP_NUMNOTEQUAL OP_VERIFY OP_DUP e5 OP_NUMNOTEQUAL OP_VERIFY OP_DUP e6 OP_NUMNOTEQUAL OP_VERIFY OP_DUP e7 OP_NUMNOTEQUAL OP_VERIFY OP_DUP e8 OP_NUMNOTEQUAL OP_VERIFY OP_DUP e9 OP_NUMNOTEQUAL OP_VERIFY OP_DUP ea OP_NUMNOTEQUAL OP_VERIFY OP_DUP eb OP_NUMNOTEQUAL OP_VERIFY OP_DUP ec OP_NUMNOTEQUAL OP_VERIFY OP_DUP ed OP_NUMNOTEQUAL OP_VERIFY OP_DUP ee OP_NUMNOTEQUAL OP_VERIFY OP_DUP ef OP_NUMNOTEQUAL OP_VERIFY OP_DUP f0 OP_NUMNOTEQUAL OP_VERIFY OP_DUP f1 OP_NUMNOTEQUAL OP_VERIFY OP_DUP f2 OP_NUMNOTEQUAL OP_VERIFY OP_DUP f3 OP_NUMNOTEQUAL OP_VERIFY OP_DUP f4 OP_NUMNOTEQUAL OP_VERIFY OP_DUP f5 OP_NUMNOTEQUAL OP_VERIFY OP_DUP f6 OP_NUMNOTEQUAL OP_VERIFY OP_DUP f7 OP_NUMNOTEQUAL OP_VERIFY OP_DUP f8 OP_NUMNOTEQUAL OP_VERIFY OP_DUP f9 OP_NUMNOTEQUAL OP_VERIFY OP_DUP fa OP_NUMNOTEQUAL OP_VERIFY OP_DUP fb OP_NUMNOTEQUAL OP_VERIFY OP_DUP fc OP_NUMNOTEQUAL OP_VERIFY OP_DUP fd OP_NUMNOTEQUAL OP_VERIFY OP_DUP fe OP_NUMNOTEQUAL OP_VERIFY OP_DROP OP_1SUB 61 OP_EQUALVERIFY OP_SHA256 06cdede198bc96a594f1685fcdc2f7b3f39a454ac97d700a1c63b2bc02cd75e1 OP_EQUALVERIFY cf OP_XOR bb OP_EQUALVERIFY OP_IFDUP OP_ADD d0 OP_EQUALVERIFY 02 OP_PICK OP_1ADD 76 OP_EQUALVERIFY OP_DUP OP_DUP OP_ADD OP_ADD 0135 OP_EQUALVERIFY OP_DROP OP_DUP cc OP_EQUAL OP_IF OP_FALSE OP_RETURN OP_ELSE 8b OP_XOR bb OP_EQUALVERIFY OP_ENDIF OP_HASH256 800ae3457a8da20b0d47089c53715054313b4974c28c6af1fefbde1fcb0fdf54 OP_EQUALVERIFY OP_DUP 60 OP_LESSTHAN OP_ADD 60 OP_EQUALVERIFY OP_SHA256 a68b412c4282555f15546cf6e1fc42893b7e07f271557ceb021821098dd66c1b OP_EQUALVERIFY OP_1SUB 68 OP_EQUALVERIFY OP_SHA256 06cdede198bc96a594f1685fcdc2f7b3f39a454ac97d700a1c63b2bc02cd75e1 OP_EQUALVERIFY d3 OP_XOR bb OP_EQUALVERIFY OP_IFDUP OP_ADD 6a OP_EQUALVERIFY 02 OP_PICK OP_1ADD 58 OP_EQUALVERIFY OP_DUP OP_DUP OP_ADD OP_ADD 013b OP_EQUALVERIFY OP_DROP OP_DUP cc OP_EQUAL OP_IF OP_FALSE OP_RETURN OP_ELSE e4 OP_XOR bb OP_EQUALVERIFY OP_ENDIF OP_DUP 32 OP_LESSTHAN OP_ADD 32 OP_EQUALVERIFY OP_SHA256 925a7bf1cc6e3b9a91aba051665a28fbc2fe5261cb6ffaaaf1decb7282252b22 OP_EQUALVERIFY 54 OP_EQUALVERIFY 4e OP_EQUALVERIFY 45 OP_EQUALVERIFY 54 OP_EQUALVERIFY 4e OP_EQUALVERIFY 49 OP_EQUALVERIFY

However, if we run it, we get a failure for the first operation: OP_DEPTH 24 OP_EQUALVERIFY. As explained earlier, the pkscript is stack based, and using this reference we understand that this operation:

  1. Puts the number of stack items onto the stack (OP_DEPTH)
  2. Pushes 0x24 to the stack (24)
  3. Fails the transction if the top two items in the stack are not equal (OP_EQUALVERIFY)

In our case, the stack is empty (0 items), and it's safe to assume that the flag should be pushed onto the stack for the script to pass.

Let's continue breaking down the script:

// Check if unlock stack size is 0x24
OP_DEPTH 
24 
OP_EQUALVERIFY 

// Verify that ( (stack_head - 1) <= 0xff)
01 
OP_PICK 
ff 
OP_LESSTHANOREQUAL 
01 
OP_EQUALVERIFY 

// Verify that ( (stack_head - 2) <= 0xff)
02 
OP_PICK 
ff 
OP_LESSTHANOREQUAL 
01 
OP_EQUALVERIFY 

// Verify that ( (stack_head - i) <= 0xff) for i in 0x3..0x24
03 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
04 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
05 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
06 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
07 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
08 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
09 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
0a OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
0b OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
0c OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
0d OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
0e OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
0f OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
10 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
11 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
12 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
13 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
14 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
15 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
16 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
17 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
18 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
19 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
1a OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
1b OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
1c OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
1d OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
1e OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
1f OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
20 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
21 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
22 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
23 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 
24 OP_PICK ff OP_LESSTHANOREQUAL 01 OP_EQUALVERIFY 

// flag[0x23] - 1 == 0x7c 
OP_1SUB 
7c 
OP_EQUALVERIFY 

// sha256(flag[0x22]) == e29c9c180c6279b0b02abd6a1801c7c04082cf486ec027aa13515e4f3884bb6b
OP_SHA256 e29c9c180c6279b0b02abd6a1801c7c04082cf486ec027aa13515e4f3884bb6b 
OP_EQUALVERIFY 

// flag[0x21] ^ 0x8a == 0xbb
8a 
OP_XOR 
bb 
OP_EQUALVERIFY 

// flag[0x20] + flag[0x20] == 0xde
OP_IFDUP 
OP_ADD 
de 
OP_EQUALVERIFY

// flag[0x1e] + 1 == 0x60
02
OP_PICK 
OP_1ADD 
60 
OP_EQUALVERIFY 

// flag[0x1f] * 3 == 0x96
OP_DUP
OP_DUP
OP_ADD 
OP_ADD 
96 
OP_EQUALVERIFY
OP_DROP

// if flag[0x1d] == 0xcc return false else flag[0x1d] ^ 0xd5 == 0xbb
OP_DUP 
cc 
OP_EQUAL 
OP_IF 
OP_FALSE 
OP_RETURN 
OP_ELSE 
d5 
OP_XOR 
bb 
OP_EQUALVERIFY 
OP_ENDIF 

// sha256(sha256(flag[0x1c])) == bed5fe7c6a43a11e4d7dbe4293f6aa2eeb65025b5f78a518fdd7447ed2ccc55e
OP_HASH256 bed5fe7c6a43a11e4d7dbe4293f6aa2eeb65025b5f78a518fdd7447ed2ccc55e 
OP_EQUALVERIFY 

// Dummy operation, result is ignored
27446f6d696e696f6e2720697320616e20696d706f7274616e7420646f63756d656e74617279 
OP_SHA1 
3a4e3aedaf36ced1a17af38a73fbc0cda118220e 
OP_EQUAL 
ff 
OP_2DROP 

// flag[0x1b] + 1 == 0x60
OP_DUP 
60 
OP_LESSTHAN 
OP_ADD 
60 
OP_EQUALVERIFY 

// sha256(flag[0x1a]) == da4ea2a5506f2693eae190d9360a1f31793c98a1adade51d93533a6f520ace1c
OP_SHA256 
da4ea2a5506f2693eae190d9360a1f31793c98a1adade51d93533a6f520ace1c 
OP_EQUALVERIFY 

// Verifying that flag[0x19] == 0x74  (by verifying that flag[0x19] != {0, 1, 2, 3, ..., 0x73, 0x75, ..., 0xfe}) 

// flag[0x19] != 0 
OP_DUP 
00 
OP_NUMNOTEQUAL 
OP_VERIFY 

// flag[0x19] != 1
OP_DUP 
01 
OP_NUMNOTEQUAL 
OP_VERIFY 

// ...
OP_DUP 02 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 03 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 04 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 05 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 06 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 07 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 08 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 09 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 0a OP_NUMNOTEQUAL OP_VERIFY OP_DUP 0b OP_NUMNOTEQUAL OP_VERIFY OP_DUP 0c OP_NUMNOTEQUAL OP_VERIFY OP_DUP 0d OP_NUMNOTEQUAL OP_VERIFY OP_DUP 0e OP_NUMNOTEQUAL OP_VERIFY OP_DUP 0f OP_NUMNOTEQUAL OP_VERIFY OP_DUP 10 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 11 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 12 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 13 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 14 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 15 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 16 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 17 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 18 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 19 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 1a OP_NUMNOTEQUAL OP_VERIFY OP_DUP 1b OP_NUMNOTEQUAL OP_VERIFY OP_DUP 1c OP_NUMNOTEQUAL OP_VERIFY OP_DUP 1d OP_NUMNOTEQUAL OP_VERIFY OP_DUP 1e OP_NUMNOTEQUAL OP_VERIFY OP_DUP 1f OP_NUMNOTEQUAL OP_VERIFY OP_DUP 20 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 21 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 22 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 23 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 24 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 25 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 26 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 27 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 28 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 29 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 2a OP_NUMNOTEQUAL OP_VERIFY OP_DUP 2b OP_NUMNOTEQUAL OP_VERIFY OP_DUP 2c OP_NUMNOTEQUAL OP_VERIFY OP_DUP 2d OP_NUMNOTEQUAL OP_VERIFY OP_DUP 2e OP_NUMNOTEQUAL OP_VERIFY OP_DUP 2f OP_NUMNOTEQUAL OP_VERIFY OP_DUP 30 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 31 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 32 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 33 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 34 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 35 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 36 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 37 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 38 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 39 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 3a OP_NUMNOTEQUAL OP_VERIFY OP_DUP 3b OP_NUMNOTEQUAL OP_VERIFY OP_DUP 3c OP_NUMNOTEQUAL OP_VERIFY OP_DUP 3d OP_NUMNOTEQUAL OP_VERIFY OP_DUP 3e OP_NUMNOTEQUAL OP_VERIFY OP_DUP 3f OP_NUMNOTEQUAL OP_VERIFY OP_DUP 40 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 41 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 42 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 43 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 44 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 45 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 46 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 47 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 48 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 49 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 4a OP_NUMNOTEQUAL OP_VERIFY OP_DUP 4b OP_NUMNOTEQUAL OP_VERIFY OP_DUP 4c OP_NUMNOTEQUAL OP_VERIFY OP_DUP 4d OP_NUMNOTEQUAL OP_VERIFY OP_DUP 4e OP_NUMNOTEQUAL OP_VERIFY OP_DUP 4f OP_NUMNOTEQUAL OP_VERIFY OP_DUP 50 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 51 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 52 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 53 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 54 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 55 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 56 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 57 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 58 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 59 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 5a OP_NUMNOTEQUAL OP_VERIFY OP_DUP 5b OP_NUMNOTEQUAL OP_VERIFY OP_DUP 5c OP_NUMNOTEQUAL OP_VERIFY OP_DUP 5d OP_NUMNOTEQUAL OP_VERIFY OP_DUP 5e OP_NUMNOTEQUAL OP_VERIFY OP_DUP 5f OP_NUMNOTEQUAL OP_VERIFY OP_DUP 60 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 61 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 62 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 63 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 64 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 65 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 66 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 67 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 68 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 69 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 6a OP_NUMNOTEQUAL OP_VERIFY OP_DUP 6b OP_NUMNOTEQUAL OP_VERIFY OP_DUP 6c OP_NUMNOTEQUAL OP_VERIFY OP_DUP 6d OP_NUMNOTEQUAL OP_VERIFY OP_DUP 6e OP_NUMNOTEQUAL OP_VERIFY OP_DUP 6f OP_NUMNOTEQUAL OP_VERIFY OP_DUP 70 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 71 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 72 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 73 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 75 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 76 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 77 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 78 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 79 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 7a OP_NUMNOTEQUAL OP_VERIFY OP_DUP 7b OP_NUMNOTEQUAL OP_VERIFY OP_DUP 7c OP_NUMNOTEQUAL OP_VERIFY OP_DUP 7d OP_NUMNOTEQUAL OP_VERIFY OP_DUP 7e OP_NUMNOTEQUAL OP_VERIFY OP_DUP 7f OP_NUMNOTEQUAL OP_VERIFY OP_DUP 80 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 81 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 82 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 83 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 84 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 85 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 86 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 87 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 88 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 89 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 8a OP_NUMNOTEQUAL OP_VERIFY OP_DUP 8b OP_NUMNOTEQUAL OP_VERIFY OP_DUP 8c OP_NUMNOTEQUAL OP_VERIFY OP_DUP 8d OP_NUMNOTEQUAL OP_VERIFY OP_DUP 8e OP_NUMNOTEQUAL OP_VERIFY OP_DUP 8f OP_NUMNOTEQUAL OP_VERIFY OP_DUP 90 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 91 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 92 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 93 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 94 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 95 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 96 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 97 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 98 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 99 OP_NUMNOTEQUAL OP_VERIFY OP_DUP 9a OP_NUMNOTEQUAL OP_VERIFY OP_DUP 9b OP_NUMNOTEQUAL OP_VERIFY OP_DUP 9c OP_NUMNOTEQUAL OP_VERIFY OP_DUP 9d OP_NUMNOTEQUAL OP_VERIFY OP_DUP 9e OP_NUMNOTEQUAL OP_VERIFY OP_DUP 9f OP_NUMNOTEQUAL OP_VERIFY OP_DUP a0 OP_NUMNOTEQUAL OP_VERIFY OP_DUP a1 OP_NUMNOTEQUAL OP_VERIFY OP_DUP a2 OP_NUMNOTEQUAL OP_VERIFY OP_DUP a3 OP_NUMNOTEQUAL OP_VERIFY OP_DUP a4 OP_NUMNOTEQUAL OP_VERIFY OP_DUP a5 OP_NUMNOTEQUAL OP_VERIFY OP_DUP a6 OP_NUMNOTEQUAL OP_VERIFY OP_DUP a7 OP_NUMNOTEQUAL OP_VERIFY OP_DUP a8 OP_NUMNOTEQUAL OP_VERIFY OP_DUP a9 OP_NUMNOTEQUAL OP_VERIFY OP_DUP aa OP_NUMNOTEQUAL OP_VERIFY OP_DUP ab OP_NUMNOTEQUAL OP_VERIFY OP_DUP ac OP_NUMNOTEQUAL OP_VERIFY OP_DUP ad OP_NUMNOTEQUAL OP_VERIFY OP_DUP ae OP_NUMNOTEQUAL OP_VERIFY OP_DUP af OP_NUMNOTEQUAL OP_VERIFY OP_DUP b0 OP_NUMNOTEQUAL OP_VERIFY OP_DUP b1 OP_NUMNOTEQUAL OP_VERIFY OP_DUP b2 OP_NUMNOTEQUAL OP_VERIFY OP_DUP b3 OP_NUMNOTEQUAL OP_VERIFY OP_DUP b4 OP_NUMNOTEQUAL OP_VERIFY OP_DUP b5 OP_NUMNOTEQUAL OP_VERIFY OP_DUP b6 OP_NUMNOTEQUAL OP_VERIFY OP_DUP b7 OP_NUMNOTEQUAL OP_VERIFY OP_DUP b8 OP_NUMNOTEQUAL OP_VERIFY OP_DUP b9 OP_NUMNOTEQUAL OP_VERIFY OP_DUP ba OP_NUMNOTEQUAL OP_VERIFY OP_DUP bb OP_NUMNOTEQUAL OP_VERIFY OP_DUP bc OP_NUMNOTEQUAL OP_VERIFY OP_DUP bd OP_NUMNOTEQUAL OP_VERIFY OP_DUP be OP_NUMNOTEQUAL OP_VERIFY OP_DUP bf OP_NUMNOTEQUAL OP_VERIFY OP_DUP c0 OP_NUMNOTEQUAL OP_VERIFY OP_DUP c1 OP_NUMNOTEQUAL OP_VERIFY OP_DUP c2 OP_NUMNOTEQUAL OP_VERIFY OP_DUP c3 OP_NUMNOTEQUAL OP_VERIFY OP_DUP c4 OP_NUMNOTEQUAL OP_VERIFY OP_DUP c5 OP_NUMNOTEQUAL OP_VERIFY OP_DUP c6 OP_NUMNOTEQUAL OP_VERIFY OP_DUP c7 OP_NUMNOTEQUAL OP_VERIFY OP_DUP c8 OP_NUMNOTEQUAL OP_VERIFY OP_DUP c9 OP_NUMNOTEQUAL OP_VERIFY OP_DUP ca OP_NUMNOTEQUAL OP_VERIFY OP_DUP cb OP_NUMNOTEQUAL OP_VERIFY OP_DUP cc OP_NUMNOTEQUAL OP_VERIFY OP_DUP cd OP_NUMNOTEQUAL OP_VERIFY OP_DUP ce OP_NUMNOTEQUAL OP_VERIFY OP_DUP cf OP_NUMNOTEQUAL OP_VERIFY OP_DUP d0 OP_NUMNOTEQUAL OP_VERIFY OP_DUP d1 OP_NUMNOTEQUAL OP_VERIFY OP_DUP d2 OP_NUMNOTEQUAL OP_VERIFY OP_DUP d3 OP_NUMNOTEQUAL OP_VERIFY OP_DUP d4 OP_NUMNOTEQUAL OP_VERIFY OP_DUP d5 OP_NUMNOTEQUAL OP_VERIFY OP_DUP d6 OP_NUMNOTEQUAL OP_VERIFY OP_DUP d7 OP_NUMNOTEQUAL OP_VERIFY OP_DUP d8 OP_NUMNOTEQUAL OP_VERIFY OP_DUP d9 OP_NUMNOTEQUAL OP_VERIFY OP_DUP da OP_NUMNOTEQUAL OP_VERIFY OP_DUP db OP_NUMNOTEQUAL OP_VERIFY OP_DUP dc OP_NUMNOTEQUAL OP_VERIFY OP_DUP dd OP_NUMNOTEQUAL OP_VERIFY OP_DUP de OP_NUMNOTEQUAL OP_VERIFY OP_DUP df OP_NUMNOTEQUAL OP_VERIFY OP_DUP e0 OP_NUMNOTEQUAL OP_VERIFY OP_DUP e1 OP_NUMNOTEQUAL OP_VERIFY OP_DUP e2 OP_NUMNOTEQUAL OP_VERIFY OP_DUP e3 OP_NUMNOTEQUAL OP_VERIFY OP_DUP e4 OP_NUMNOTEQUAL OP_VERIFY OP_DUP e5 OP_NUMNOTEQUAL OP_VERIFY OP_DUP e6 OP_NUMNOTEQUAL OP_VERIFY OP_DUP e7 OP_NUMNOTEQUAL OP_VERIFY OP_DUP e8 OP_NUMNOTEQUAL OP_VERIFY OP_DUP e9 OP_NUMNOTEQUAL OP_VERIFY OP_DUP ea OP_NUMNOTEQUAL OP_VERIFY OP_DUP eb OP_NUMNOTEQUAL OP_VERIFY OP_DUP ec OP_NUMNOTEQUAL OP_VERIFY OP_DUP ed OP_NUMNOTEQUAL OP_VERIFY OP_DUP ee OP_NUMNOTEQUAL OP_VERIFY OP_DUP ef OP_NUMNOTEQUAL OP_VERIFY OP_DUP f0 OP_NUMNOTEQUAL OP_VERIFY OP_DUP f1 OP_NUMNOTEQUAL OP_VERIFY OP_DUP f2 OP_NUMNOTEQUAL OP_VERIFY OP_DUP f3 OP_NUMNOTEQUAL OP_VERIFY OP_DUP f4 OP_NUMNOTEQUAL OP_VERIFY OP_DUP f5 OP_NUMNOTEQUAL OP_VERIFY OP_DUP f6 OP_NUMNOTEQUAL OP_VERIFY OP_DUP f7 OP_NUMNOTEQUAL OP_VERIFY OP_DUP f8 OP_NUMNOTEQUAL OP_VERIFY OP_DUP f9 OP_NUMNOTEQUAL OP_VERIFY OP_DUP fa OP_NUMNOTEQUAL OP_VERIFY OP_DUP fb OP_NUMNOTEQUAL OP_VERIFY OP_DUP fc OP_NUMNOTEQUAL OP_VERIFY OP_DUP fd OP_NUMNOTEQUAL OP_VERIFY OP_DUP fe OP_NUMNOTEQUAL OP_VERIFY OP_DROP 

// flag[0x18] - 1 == 0x61
OP_1SUB
61 
OP_EQUALVERIFY 

// sha256(flag[0x17]) == 06cdede198bc96a594f1685fcdc2f7b3f39a454ac97d700a1c63b2bc02cd75e1
OP_SHA256 
06cdede198bc96a594f1685fcdc2f7b3f39a454ac97d700a1c63b2bc02cd75e1 
OP_EQUALVERIFY 

// flag[0x16] ^ 0xcf == 0xbb
cf 
OP_XOR 
bb 
OP_EQUALVERIFY 

// flag[0x15] * 2 == 0xd0
OP_IFDUP 
OP_ADD 
d0 
OP_EQUALVERIFY 

// flag[0x13] + 1 == 0x76
02 
OP_PICK 
OP_1ADD 
76 
OP_EQUALVERIFY 

// flag[0x14] * 3 == 0x135
OP_DUP
OP_DUP 
OP_ADD 
OP_ADD 
0135 
OP_EQUALVERIFY 
OP_DROP

// if flag[0x12] == 0xcc return false else flag[0x12] ^ 0x8b == 0xbb
OP_DUP 
cc 
OP_EQUAL 
OP_IF 
OP_FALSE 
OP_RETURN 
OP_ELSE 
8b 
OP_XOR 
bb 
OP_EQUALVERIFY 
OP_ENDIF 

// sha256(sha256(flag[0x11])) == 800ae3457a8da20b0d47089c53715054313b4974c28c6af1fefbde1fcb0fdf54
OP_HASH256 
800ae3457a8da20b0d47089c53715054313b4974c28c6af1fefbde1fcb0fdf54 
OP_EQUALVERIFY 

// flag[0x10] + 1 == 0x60
OP_DUP
60 
OP_LESSTHAN 
OP_ADD 
60 
OP_EQUALVERIFY 

// sha256(flag[0xf]) == a68b412c4282555f15546cf6e1fc42893b7e07f271557ceb021821098dd66c1b
OP_SHA256 
a68b412c4282555f15546cf6e1fc42893b7e07f271557ceb021821098dd66c1b 
OP_EQUALVERIFY 

// flag[0xe] - 1 == 0x68
OP_1SUB 
68 
OP_EQUALVERIFY 

// sha256(flag[0xd]) == 06cdede198bc96a594f1685fcdc2f7b3f39a454ac97d700a1c63b2bc02cd75e1
OP_SHA256 
06cdede198bc96a594f1685fcdc2f7b3f39a454ac97d700a1c63b2bc02cd75e1 
OP_EQUALVERIFY 

// flag[0xc] ^ 0xd3 == 0xbb
d3 
OP_XOR 
bb 
OP_EQUALVERIFY 

// flag[0xb] * 2 == 0x6a
OP_IFDUP 
OP_ADD 
6a 
OP_EQUALVERIFY 

// flag[0x9] + 1 == 0x58
02 
OP_PICK 
OP_1ADD 
58 
OP_EQUALVERIFY 

// flag[0xa] * 3 == 0x13b
OP_DUP 
OP_DUP 
OP_ADD 
OP_ADD 
013b 
OP_EQUALVERIFY 
OP_DROP 

// if flag[0x8] == 0xcc return false else flag[0x8] ^ 0xe4 == 0xbb
OP_DUP 
cc 
OP_EQUAL
OP_IF 
OP_FALSE 
OP_RETURN 
OP_ELSE 
e4 
OP_XOR 
bb 
OP_EQUALVERIFY 
OP_ENDIF 

// flag[0x7] + 1 == 0x32
OP_DUP
32 
OP_LESSTHAN 
OP_ADD 
32 
OP_EQUALVERIFY 

// sha256(flag[0x6]) == 925a7bf1cc6e3b9a91aba051665a28fbc2fe5261cb6ffaaaf1decb7282252b22
OP_SHA256 
925a7bf1cc6e3b9a91aba051665a28fbc2fe5261cb6ffaaaf1decb7282252b22 
OP_EQUALVERIFY 

// flag[0x5] == 0x54
54 
OP_EQUALVERIFY 

// flag[0x4] == 0x4e
4e 
OP_EQUALVERIFY 

// flag[0x3] == 0x45
45 
OP_EQUALVERIFY 

// flag[0x2] == 0x54
54 
OP_EQUALVERIFY 

// flag[0x1] == 0x4e
4e 
OP_EQUALVERIFY 

// flag[0x0] == 0x49
49 
OP_EQUALVERIFY

Putting it all together, we get [73, 78, 84, 69, 78, 84, 123, 49, 95, 87, 105, 53, 104, 95, 105, 100, 95, 98, 48, 117, 103, 104, 116, 95, 98, 116, 99, 95, 105, 110, 95, 50, 111, 49, 50, 125].

We can add the following to the top of the script to get it to execute successfully:

49
4e
54
45
4e
54
7b
31
5f
57
69
35
68
5f
69
64
5f
62
30
75
67
68
74
5f
62
74
63
5f
69
6e
5f
32
6f
31
32
7d

The flag itself, after translating to ASCII, is INTENT{1_Wi5h_id_b0ught_btc_in_2o12}.