diff options
author | Dimitry <dimitry@ethereum.org> | 2018-12-11 23:02:43 +0800 |
---|---|---|
committer | Dimitry <dimitry@ethereum.org> | 2018-12-11 23:02:43 +0800 |
commit | f427fd33fd42234c09ffcbdffbfe2ff56cb51cf2 (patch) | |
tree | 58b5eaf7e67a4d90b17b5bc66c5102d4e2acf098 /src | |
parent | c45bfa376509561f70c06e5e4fd02569fdee09eb (diff) | |
download | dexon-tests-f427fd33fd42234c09ffcbdffbfe2ff56cb51cf2.tar dexon-tests-f427fd33fd42234c09ffcbdffbfe2ff56cb51cf2.tar.gz dexon-tests-f427fd33fd42234c09ffcbdffbfe2ff56cb51cf2.tar.bz2 dexon-tests-f427fd33fd42234c09ffcbdffbfe2ff56cb51cf2.tar.lz dexon-tests-f427fd33fd42234c09ffcbdffbfe2ff56cb51cf2.tar.xz dexon-tests-f427fd33fd42234c09ffcbdffbfe2ff56cb51cf2.tar.zst dexon-tests-f427fd33fd42234c09ffcbdffbfe2ff56cb51cf2.zip |
extcodecopy bounds
Diffstat (limited to 'src')
-rw-r--r-- | src/BlockchainTestsFiller/GeneralStateTests/stExtCodeHash/extCodeCopyBounds_d0g0v0Filler.json | 86 | ||||
-rw-r--r-- | src/GeneralStateTestsFiller/stExtCodeHash/extCodeCopyBoundsFiller.yml | 76 |
2 files changed, 162 insertions, 0 deletions
diff --git a/src/BlockchainTestsFiller/GeneralStateTests/stExtCodeHash/extCodeCopyBounds_d0g0v0Filler.json b/src/BlockchainTestsFiller/GeneralStateTests/stExtCodeHash/extCodeCopyBounds_d0g0v0Filler.json new file mode 100644 index 000000000..5db68a7ee --- /dev/null +++ b/src/BlockchainTestsFiller/GeneralStateTests/stExtCodeHash/extCodeCopyBounds_d0g0v0Filler.json @@ -0,0 +1,86 @@ +{ + "extCodeCopyBounds_d0g0v0" : { + "_info" : { + "comment" : "EXTCODECOPY edge case https://github.com/ethereum/tests/issues/438" + }, + "blocks" : [ + { + "blockHeaderPremine" : { + "difficulty" : "0x020000", + "gasLimit" : "0x0f4240", + "timestamp" : "0x03e8", + "updatePoW" : "1" + }, + "transactions" : [ + { + "data" : "0x", + "gasLimit" : "0x061a80", + "gasPrice" : "0x01", + "nonce" : "0x00", + "r" : "0xae29a79903b187c6d075320f9834a330b5134244c7fb0476eba58cd87b175fd6", + "s" : "0x27a8f85308f5f08f4e2f6b2e23d9dcfd740108f8f96517e50c9e1dc86288a673", + "to" : "0x095e7baea6a6c7c4c2dfeb977efac326af552d87", + "v" : "0x1c", + "value" : "0x01" + } + ], + "uncleHeaders" : [ + ] + } + ], + "expect" : [ + { + "network" : "Constantinople", + "result" : { + "0x095e7baea6a6c7c4c2dfeb977efac326af552d87" : { + "balance" : "0x0de0b6b3a7640001", + "storage" : { + "0x04" : "0x600b606355600a606355000000000000000000000000000000000000000000" + } + } + } + } + ], + "genesisBlockHeader" : { + "bloom" : "00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000", + "coinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba", + "difficulty" : "131072", + "extraData" : "0x42", + "gasLimit" : "0x0f4240", + "gasUsed" : "0", + "mixHash" : "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421", + "nonce" : "0x0102030405060708", + "number" : "0", + "parentHash" : "0x0000000000000000000000000000000000000000000000000000000000000000", + "receiptTrie" : "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421", + "stateRoot" : "0xf99eb1626cfa6db435c0836235942d7ccaa935f1ae247d3f1c21e495685f903a", + "timestamp" : "0x03b6", + "transactionsTrie" : "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421", + "uncleHash" : "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347" + }, + "pre" : { + "0x095e7baea6a6c7c4c2dfeb977efac326af552d87" : { + "balance" : "0x0de0b6b3a7640000", + "code" : "0x61138874010000000000000000000000000000000000000000600173e713449c212d891357cc2966816b1d528cfb59e03c600051600055602051600155600c74010000000000000000000000000000000000000000600173e713449c212d891357cc2966816b1d528cfb59e03c600051600255602051600355600c6005600173e713449c212d891357cc2966816b1d528cfb59e03c600051600455602051600555", + "nonce" : "0x00", + "storage" : { + } + }, + "0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b" : { + "balance" : "0x0de0b6b3a7640000", + "code" : "0x00", + "nonce" : "0x00", + "storage" : { + } + }, + "0xe713449c212d891357cc2966816b1d528cfb59e0" : { + "balance" : "0x00", + "code" : "0x600c606355600b606355600a606355", + "nonce" : "0x00", + "storage" : { + } + } + }, + "sealEngine" : "NoProof" + } +}
\ No newline at end of file diff --git a/src/GeneralStateTestsFiller/stExtCodeHash/extCodeCopyBoundsFiller.yml b/src/GeneralStateTestsFiller/stExtCodeHash/extCodeCopyBoundsFiller.yml new file mode 100644 index 000000000..89dc9e504 --- /dev/null +++ b/src/GeneralStateTestsFiller/stExtCodeHash/extCodeCopyBoundsFiller.yml @@ -0,0 +1,76 @@ +# EXTCODECOPY edge case https://github.com/ethereum/tests/issues/438 +--- +extCodeCopyBounds: + env: + currentCoinbase: 2adc25665018aa1fe0e6bc666dac8fc2697ff9ba + currentDifficulty: '0x20000' + currentGasLimit: "1000000" + currentNumber: "1" + currentTimestamp: "1000" + previousHash: 5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6 + _info: + comment: "EXTCODECOPY edge case https://github.com/ethereum/tests/issues/438" + pre: + 095e7baea6a6c7c4c2dfeb977efac326af552d87: + balance: '1000000000000000000' + code: | + { + ;; code position is way too high + (EXTCODECOPY 0xe713449c212d891357cc2966816b1d528cfb59e0 1 0x010000000000000000000000000000000000000000 5000) + + [[0]] (MLOAD 0) + [[1]] (MLOAD 32) + + (EXTCODECOPY 0xe713449c212d891357cc2966816b1d528cfb59e0 1 0x010000000000000000000000000000000000000000 12) + + [[2]] (MLOAD 0) + [[3]] (MLOAD 32) + + (EXTCODECOPY 0xe713449c212d891357cc2966816b1d528cfb59e0 1 5 12) + + [[4]] (MLOAD 0) + [[5]] (MLOAD 32) + } + nonce: '0' + storage: {} + e713449c212d891357cc2966816b1d528cfb59e0: + balance: '0' + code: | + { + ;; Some code + [[99]] 12 + [[99]] 11 + [[99]] 10 + } + nonce: '0' + storage: { + } + a94f5374fce5edbc8e2a8697c15331677e6ebf0b: + balance: '1000000000000000000' + code: '0x00' + nonce: '0' + storage: {} + expect: + - indexes: + data: !!int -1 + gas: !!int -1 + value: !!int -1 + network: + - '>=Constantinople' + result: + 095e7baea6a6c7c4c2dfeb977efac326af552d87: + balance: '1000000000000000001' + storage: { + 4: '0x600b606355600a606355000000000000000000000000000000000000000000' + } + transaction: + data: + - '' + gasLimit: + - '400000' + gasPrice: '1' + nonce: '0' + secretKey: 45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8 + to: 095e7baea6a6c7c4c2dfeb977efac326af552d87 + value: + - '1' |