Skip to content

Commit

Permalink
Merge pull request #568 from ethereum/moreextcodehash
Browse files Browse the repository at this point in the history
extcodehash of account that suicide in a subcall
  • Loading branch information
winsvega authored Dec 12, 2018
2 parents 7d92418 + afe968f commit 3c239e6
Show file tree
Hide file tree
Showing 4 changed files with 403 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,138 @@
{
"extCodeHashSubcallSuicide_d0g0v0_Constantinople" : {
"_info" : {
"comment" : "transaction to B | B call to A | A delegatecall/callcode to C (C has selfdestruct) | A selfdestructed. returned to B. now we could check extcodehash of A (in account B code)",
"filledwith" : "testeth 1.5.0-alpha.7-5+commit.4c8a143b",
"lllcversion" : "Version: 0.5.0-develop.2018.11.9+commit.9709dfe0.Linux.g++",
"source" : "src/BlockchainTestsFiller/GeneralStateTests/stExtCodeHash/extCodeHashSubcallSuicide_d0g0v0Filler.json",
"sourceHash" : "f8d087f2a45904315e9f4ff9bc00b6d64db7dae4a28cfc6edbfd6efc4cc07d52"
},
"blocks" : [
{
"blockHeader" : {
"bloom" : "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"coinbase" : "0x2adc25665018aa1fe0e6bc666dac8fc2697ff9ba",
"difficulty" : "0x020000",
"extraData" : "",
"gasLimit" : "0x989680",
"gasUsed" : "0x0257e8",
"hash" : "0x59449ef18e7b86f0646f2a55cc8465c255460495282b93b08eb197ff684d38ec",
"mixHash" : "0x0000000000000000000000000000000000000000000000000000000000000000",
"nonce" : "0x0000000000000000",
"number" : "0x01",
"parentHash" : "0x1ccc350465188724bcfd4523c3ac13547643c0a99f84f0ecbf8bee4f52244418",
"receiptTrie" : "0x35700ae09128a9dc8a251674ed5b6fdea2983729336f1be5845b4f7f1c8d97d9",
"stateRoot" : "0xded91bd07aa705f16635d41d05808dd45ecd9aa7c1f0fd2c2576864ee173f0d8",
"timestamp" : "0x03e8",
"transactionsTrie" : "0xec6215c6ff240ca9ace2b22f22fc10a8a37b496f9b815a431cc003a4707e6b64",
"uncleHash" : "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347"
},
"rlp" : "0xf9025ff901f8a01ccc350465188724bcfd4523c3ac13547643c0a99f84f0ecbf8bee4f52244418a01dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347942adc25665018aa1fe0e6bc666dac8fc2697ff9baa0ded91bd07aa705f16635d41d05808dd45ecd9aa7c1f0fd2c2576864ee173f0d8a0ec6215c6ff240ca9ace2b22f22fc10a8a37b496f9b815a431cc003a4707e6b64a035700ae09128a9dc8a251674ed5b6fdea2983729336f1be5845b4f7f1c8d97d9b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000830200000183989680830257e88203e880a00000000000000000000000000000000000000000000000000000000000000000880000000000000000f861f85f80018307a12094b00000000000000000000000000000000000000001801c9f207768aa22a4c6f8da0844ba3f0420f32cb48ae946f5431ef5ceaa290d73dfa0505965f889f738e0c5d6da39d4d8ffef5c8256475e1066a7f215017ac205c68dc0",
"transactions" : [
{
"data" : "0x",
"gasLimit" : "0x07a120",
"gasPrice" : "0x01",
"nonce" : "0x00",
"r" : "0x207768aa22a4c6f8da0844ba3f0420f32cb48ae946f5431ef5ceaa290d73df",
"s" : "0x505965f889f738e0c5d6da39d4d8ffef5c8256475e1066a7f215017ac205c68d",
"to" : "0xb000000000000000000000000000000000000000",
"v" : "0x1c",
"value" : "0x01"
}
],
"uncleHeaders" : [
]
}
],
"genesisBlockHeader" : {
"bloom" : "0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"coinbase" : "0x2adc25665018aa1fe0e6bc666dac8fc2697ff9ba",
"difficulty" : "0x020000",
"extraData" : "0x42",
"gasLimit" : "0x989680",
"gasUsed" : "0x00",
"hash" : "0x1ccc350465188724bcfd4523c3ac13547643c0a99f84f0ecbf8bee4f52244418",
"mixHash" : "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",
"nonce" : "0x0102030405060708",
"number" : "0x00",
"parentHash" : "0x0000000000000000000000000000000000000000000000000000000000000000",
"receiptTrie" : "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",
"stateRoot" : "0x7c45694ca697346ae17ce0a8835b5c5f9ccffadf44f39bd608ebed72f6536d56",
"timestamp" : "0x03b6",
"transactionsTrie" : "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",
"uncleHash" : "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347"
},
"genesisRLP" : "0xf901faf901f5a00000000000000000000000000000000000000000000000000000000000000000a01dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347942adc25665018aa1fe0e6bc666dac8fc2697ff9baa07c45694ca697346ae17ce0a8835b5c5f9ccffadf44f39bd608ebed72f6536d56a056e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421a056e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421b9010000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000830200008083989680808203b642a056e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421880102030405060708c0c0",
"lastblockhash" : "0x59449ef18e7b86f0646f2a55cc8465c255460495282b93b08eb197ff684d38ec",
"network" : "Constantinople",
"postState" : {
"0x2adc25665018aa1fe0e6bc666dac8fc2697ff9ba" : {
"balance" : "0x1bc16d674eca57e8",
"code" : "",
"nonce" : "0x00",
"storage" : {
}
},
"0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
"balance" : "0x1bc16d674ec5a817",
"code" : "0x00",
"nonce" : "0x01",
"storage" : {
}
},
"0xb000000000000000000000000000000000000000" : {
"balance" : "0x0de0b6b3a7640001",
"code" : "0x73a0000000000000000000000000000000000000003f60015573a0000000000000000000000000000000000000003b60025560206000600073a0000000000000000000000000000000000000003c6000516003556020600060006000600073a00000000000000000000000000000000000000062055730f15073a0000000000000000000000000000000000000003f60045573a0000000000000000000000000000000000000003b60055560206000600073a0000000000000000000000000000000000000003c6000516006556020600060006000600073a00000000000000000000000000000000000000062055730f1600755",
"nonce" : "0x00",
"storage" : {
"0x01" : "0x3c2265ca60a41f7da0c762b50885e4e7fd9a963716a3a03cfbea4eca95a854f9",
"0x02" : "0x24",
"0x03" : "0x6020600060006000600073c00000000000000000000000000000000000000062",
"0x04" : "0x3c2265ca60a41f7da0c762b50885e4e7fd9a963716a3a03cfbea4eca95a854f9",
"0x05" : "0x24",
"0x06" : "0x6020600060006000600073c00000000000000000000000000000000000000062",
"0x07" : "0x01"
}
},
"0xc000000000000000000000000000000000000000" : {
"balance" : "0x0de0b6b3a7640000",
"code" : "0x73a94f5374fce5edbc8e2a8697c15331677e6ebf0bff",
"nonce" : "0x00",
"storage" : {
}
}
},
"pre" : {
"0xa000000000000000000000000000000000000000" : {
"balance" : "0x0de0b6b3a7640000",
"code" : "0x6020600060006000600073c00000000000000000000000000000000000000062055730f2",
"nonce" : "0x00",
"storage" : {
}
},
"0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
"balance" : "0x0de0b6b3a7640000",
"code" : "0x00",
"nonce" : "0x00",
"storage" : {
}
},
"0xb000000000000000000000000000000000000000" : {
"balance" : "0x0de0b6b3a7640000",
"code" : "0x73a0000000000000000000000000000000000000003f60015573a0000000000000000000000000000000000000003b60025560206000600073a0000000000000000000000000000000000000003c6000516003556020600060006000600073a00000000000000000000000000000000000000062055730f15073a0000000000000000000000000000000000000003f60045573a0000000000000000000000000000000000000003b60055560206000600073a0000000000000000000000000000000000000003c6000516006556020600060006000600073a00000000000000000000000000000000000000062055730f1600755",
"nonce" : "0x00",
"storage" : {
}
},
"0xc000000000000000000000000000000000000000" : {
"balance" : "0x0de0b6b3a7640000",
"code" : "0x73a94f5374fce5edbc8e2a8697c15331677e6ebf0bff",
"nonce" : "0x00",
"storage" : {
}
}
},
"sealEngine" : "NoProof"
}
}
77 changes: 77 additions & 0 deletions GeneralStateTests/stExtCodeHash/extCodeHashSubcallSuicide.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,77 @@
{
"extCodeHashSubcallSuicide" : {
"_info" : {
"comment" : "transaction to B | B call to A | A delegatecall/callcode to C (C has selfdestruct) | A selfdestructed. returned to B. now we could check extcodehash of A (in account B code)",
"filledwith" : "testeth 1.5.0-alpha.7-5+commit.4c8a143b",
"lllcversion" : "Version: 0.5.0-develop.2018.11.9+commit.9709dfe0.Linux.g++",
"source" : "src/GeneralStateTestsFiller/stExtCodeHash/extCodeHashSubcallSuicideFiller.yml",
"sourceHash" : "f946bb371a53d7ccab804a5ec06755a634a3288d176623c314fd3fcefe2a729d"
},
"env" : {
"currentCoinbase" : "0x2adc25665018aa1fe0e6bc666dac8fc2697ff9ba",
"currentDifficulty" : "0x20000",
"currentGasLimit" : "0x989680",
"currentNumber" : "0x01",
"currentTimestamp" : "0x03e8",
"previousHash" : "0x5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6"
},
"post" : {
"Constantinople" : [
{
"hash" : "0x08075fa19334d93e4a2b0c7730516a9be14738c938c2603d08e795a879e84a37",
"indexes" : {
"data" : 0,
"gas" : 0,
"value" : 0
},
"logs" : "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347"
}
]
},
"pre" : {
"0xa000000000000000000000000000000000000000" : {
"balance" : "0x0de0b6b3a7640000",
"code" : "0x6020600060006000600073c00000000000000000000000000000000000000062055730f2",
"nonce" : "0x00",
"storage" : {
}
},
"0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
"balance" : "0x0de0b6b3a7640000",
"code" : "0x00",
"nonce" : "0x00",
"storage" : {
}
},
"0xb000000000000000000000000000000000000000" : {
"balance" : "0x0de0b6b3a7640000",
"code" : "0x73a0000000000000000000000000000000000000003f60015573a0000000000000000000000000000000000000003b60025560206000600073a0000000000000000000000000000000000000003c6000516003556020600060006000600073a00000000000000000000000000000000000000062055730f15073a0000000000000000000000000000000000000003f60045573a0000000000000000000000000000000000000003b60055560206000600073a0000000000000000000000000000000000000003c6000516006556020600060006000600073a00000000000000000000000000000000000000062055730f1600755",
"nonce" : "0x00",
"storage" : {
}
},
"0xc000000000000000000000000000000000000000" : {
"balance" : "0x0de0b6b3a7640000",
"code" : "0x73a94f5374fce5edbc8e2a8697c15331677e6ebf0bff",
"nonce" : "0x00",
"storage" : {
}
}
},
"transaction" : {
"data" : [
"0x"
],
"gasLimit" : [
"0x07a120"
],
"gasPrice" : "0x01",
"nonce" : "0x00",
"secretKey" : "0x45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8",
"to" : "0xb000000000000000000000000000000000000000",
"value" : [
"0x01"
]
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,100 @@
{
"extCodeHashSubcallSuicide_d0g0v0" : {
"_info" : {
"comment" : "transaction to B | B call to A | A delegatecall/callcode to C (C has selfdestruct) | A selfdestructed. returned to B. now we could check extcodehash of A (in account B code)"
},
"blocks" : [
{
"blockHeaderPremine" : {
"difficulty" : "0x020000",
"gasLimit" : "0x989680",
"timestamp" : "0x03e8",
"updatePoW" : "1"
},
"transactions" : [
{
"data" : "0x",
"gasLimit" : "0x07a120",
"gasPrice" : "0x01",
"nonce" : "0x00",
"r" : "0x207768aa22a4c6f8da0844ba3f0420f32cb48ae946f5431ef5ceaa290d73df",
"s" : "0x505965f889f738e0c5d6da39d4d8ffef5c8256475e1066a7f215017ac205c68d",
"to" : "0xb000000000000000000000000000000000000000",
"v" : "0x1c",
"value" : "0x01"
}
],
"uncleHeaders" : [
]
}
],
"expect" : [
{
"network" : "Constantinople",
"result" : {
"0xa000000000000000000000000000000000000000" : {
},
"0xb000000000000000000000000000000000000000" : {
"storage" : {
"0x01" : "0x3c2265ca60a41f7da0c762b50885e4e7fd9a963716a3a03cfbea4eca95a854f9",
"0x02" : "0x24",
"0x03" : "0x6020600060006000600073c00000000000000000000000000000000000000062",
"0x04" : "0x3c2265ca60a41f7da0c762b50885e4e7fd9a963716a3a03cfbea4eca95a854f9",
"0x05" : "0x24",
"0x06" : "0x6020600060006000600073c00000000000000000000000000000000000000062",
"0x07" : "0x01"
}
}
}
}
],
"genesisBlockHeader" : {
"bloom" : "00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000",
"coinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba",
"difficulty" : "131072",
"extraData" : "0x42",
"gasLimit" : "0x989680",
"gasUsed" : "0",
"mixHash" : "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",
"nonce" : "0x0102030405060708",
"number" : "0",
"parentHash" : "0x0000000000000000000000000000000000000000000000000000000000000000",
"receiptTrie" : "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",
"stateRoot" : "0xf99eb1626cfa6db435c0836235942d7ccaa935f1ae247d3f1c21e495685f903a",
"timestamp" : "0x03b6",
"transactionsTrie" : "0x56e81f171bcc55a6ff8345e692c0f86e5b48e01b996cadc001622fb5e363b421",
"uncleHash" : "0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347"
},
"pre" : {
"0xa000000000000000000000000000000000000000" : {
"balance" : "0x0de0b6b3a7640000",
"code" : "0x6020600060006000600073c00000000000000000000000000000000000000062055730f2",
"nonce" : "0x00",
"storage" : {
}
},
"0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
"balance" : "0x0de0b6b3a7640000",
"code" : "0x00",
"nonce" : "0x00",
"storage" : {
}
},
"0xb000000000000000000000000000000000000000" : {
"balance" : "0x0de0b6b3a7640000",
"code" : "0x73a0000000000000000000000000000000000000003f60015573a0000000000000000000000000000000000000003b60025560206000600073a0000000000000000000000000000000000000003c6000516003556020600060006000600073a00000000000000000000000000000000000000062055730f15073a0000000000000000000000000000000000000003f60045573a0000000000000000000000000000000000000003b60055560206000600073a0000000000000000000000000000000000000003c6000516006556020600060006000600073a00000000000000000000000000000000000000062055730f1600755",
"nonce" : "0x00",
"storage" : {
}
},
"0xc000000000000000000000000000000000000000" : {
"balance" : "0x0de0b6b3a7640000",
"code" : "0x73a94f5374fce5edbc8e2a8697c15331677e6ebf0bff",
"nonce" : "0x00",
"storage" : {
}
}
},
"sealEngine" : "NoProof"
}
}
Loading

0 comments on commit 3c239e6

Please sign in to comment.