You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1254 lines
55 KiB
1254 lines
55 KiB
{
|
|
"ContractInheritance" : {
|
|
"env" : {
|
|
"currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba",
|
|
"currentDifficulty" : "45678256",
|
|
"currentGasLimit" : "1000000000000000000000",
|
|
"currentNumber" : "120",
|
|
"currentTimestamp" : 1,
|
|
"previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6"
|
|
},
|
|
"expect" : {
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"storage" : {
|
|
"0x" : "0x01"
|
|
}
|
|
}
|
|
},
|
|
"pre" :
|
|
{
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"balance" : "100000",
|
|
"//" : "contract base ",
|
|
"//" : "{ ",
|
|
"//" : " function methodA() returns (uint32) ",
|
|
"//" : " { ",
|
|
"//" : " return 1; ",
|
|
"//" : " } ",
|
|
"//" : "} ",
|
|
"//" : " ",
|
|
"//" : "contract frombase is base ",
|
|
"//" : "{ ",
|
|
"//" : " function methodA() returns (uint32) ",
|
|
"//" : " { ",
|
|
"//" : " return 2; ",
|
|
"//" : " } ",
|
|
"//" : "} ",
|
|
"//" : " ",
|
|
"//" : "contract main ",
|
|
"//" : "{ ",
|
|
"//" : " bool returnValue; ",
|
|
"//" : " function run() returns (bool) ",
|
|
"//" : " { ",
|
|
"//" : " returnValue = testInheretance(); ",
|
|
"//" : " return returnValue; ",
|
|
"//" : " } ",
|
|
"//" : " ",
|
|
"//" : " function testInheretance() returns (bool res) ",
|
|
"//" : " { ",
|
|
"//" : " res = true; ",
|
|
"//" : " base contract1 = new base(); ",
|
|
"//" : " if (contract1.methodA() != 1) ",
|
|
"//" : " return false; ",
|
|
"//" : " ",
|
|
"//" : " frombase contract2 = new frombase(); ",
|
|
"//" : " if (contract2.methodA() != 2) ",
|
|
"//" : " return false; ",
|
|
"//" : " } ",
|
|
"//" : "} ",
|
|
"code" : "0x7c010000000000000000000000000000000000000000000000000000000060003504633e0bca3b8114610039578063c0406226146100a857005b6100b55b600160008060456101ec8339604560006000f091508173ffffffffffffffffffffffffffffffffffffffff166381bda09b60206000827c010000000000000000000000000000000000000000000000000000000002600052600460006000866161da5a03f161011957005b6100bf60006100c961003d565b8060005260206000f35b8060005260206000f35b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016919091179081905560ff16919050565b505060005163ffffffff166002141561019d575b5b505090565b505060005163ffffffff1660011415610194575b60456101a7600039604560006000f090508073ffffffffffffffffffffffffffffffffffffffff166381bda09b60206000827c010000000000000000000000000000000000000000000000000000000002600052600460006000866161da5a03f16100ff57005b60009250610114565b600092506101145600603980600c6000396000f3007c0100000000000000000000000000000000000000000000000000000000600035046381bda09b8114602d57005b60026000818152602090f3603980600c6000396000f3007c0100000000000000000000000000000000000000000000000000000000600035046381bda09b8114602d57005b60016000818152602090f3",
|
|
"nonce" : "0",
|
|
"storage" : {
|
|
}
|
|
},
|
|
"a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
|
|
"balance" : "50000000",
|
|
"nonce" : "0",
|
|
"code" : "",
|
|
"storage": {}
|
|
}
|
|
},
|
|
"transaction" :
|
|
{
|
|
"data" : "run()",
|
|
"data" : "0xc0406226",
|
|
"gasLimit" : "35000000",
|
|
"gasPrice" : "1",
|
|
"nonce" : "0",
|
|
"secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8",
|
|
"to" : "095e7baea6a6c7c4c2dfeb977efac326af552d87",
|
|
"value" : "0"
|
|
}
|
|
},
|
|
|
|
"TestOverflow" : {
|
|
"env" : {
|
|
"currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba",
|
|
"currentDifficulty" : "45678256",
|
|
"currentGasLimit" : "1000000000000000000000",
|
|
"currentNumber" : "120",
|
|
"currentTimestamp" : 1,
|
|
"previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6"
|
|
},
|
|
"expect" : {
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"storage" : {
|
|
"0x" : "0x01"
|
|
}
|
|
}
|
|
},
|
|
"pre" :
|
|
{
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"balance" : "100000",
|
|
"//" : "contract main ",
|
|
"//" : "{ ",
|
|
"//" : " bool returnValue; ",
|
|
"//" : " function run() returns (bool) ",
|
|
"//" : " { ",
|
|
"//" : " returnValue = testOverflow(); ",
|
|
"//" : " return returnValue; ",
|
|
"//" : " } ",
|
|
"//" : " ",
|
|
"//" : " function testOverflow() returns (bool res) ",
|
|
"//" : " { ",
|
|
"//" : " res = true; ",
|
|
"//" : " uint256 a = 115792089237316195423570985008687907853269984665640564039457584007913129639935; ",
|
|
"//" : " if (a + 1 != 0) ",
|
|
"//" : " return false; ",
|
|
"//" : " ",
|
|
"//" : " uint32 b = 4294967295; ",
|
|
"//" : " if (b + 1 != 0) ",
|
|
"//" : " return false; ",
|
|
"//" : " ",
|
|
"//" : " uint64 c = 18446744073709551615; ",
|
|
"//" : " if (c + 1 != 0) ",
|
|
"//" : " return false; ",
|
|
"//" : " } ",
|
|
"//" : "} ",
|
|
"code" : "0x6000357c0100000000000000000000000000000000000000000000000000000000900480638040cac41461003a578063c04062261461004c57005b610042610099565b8060005260206000f35b61005461005e565b8060005260206000f35b6000610068610099565b600060006101000a81548160ff02191690830217905550600060009054906101000a900460ff169050610096565b90565b60006000600060006001935083507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff925060006001840114156100db576100e4565b6000935061013b565b63ffffffff915060006001830163ffffffff1614156101025761010b565b6000935061013b565b67ffffffffffffffff905060006001820167ffffffffffffffff1614156101315761013a565b6000935061013b565b5b5050509056",
|
|
"nonce" : "0",
|
|
"storage" : {
|
|
}
|
|
},
|
|
"a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
|
|
"balance" : "50000000",
|
|
"nonce" : "0",
|
|
"code" : "",
|
|
"storage": {}
|
|
}
|
|
},
|
|
"transaction" :
|
|
{
|
|
"data" : "run()",
|
|
"data" : "0xc0406226",
|
|
"gasLimit" : "35000000",
|
|
"gasPrice" : "1",
|
|
"nonce" : "0",
|
|
"secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8",
|
|
"to" : "095e7baea6a6c7c4c2dfeb977efac326af552d87",
|
|
"value" : "0"
|
|
}
|
|
},
|
|
|
|
"TestStoreGasPrices" : {
|
|
"env" : {
|
|
"currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba",
|
|
"currentDifficulty" : "45678256",
|
|
"currentGasLimit" : "1000000000000000000000",
|
|
"currentNumber" : "120",
|
|
"currentTimestamp" : 1,
|
|
"previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6"
|
|
},
|
|
"expect" : {
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"storage" : {
|
|
"0x" : "0x4e2d",
|
|
"0x01" : "0x1395",
|
|
"0x02" : "0x1395",
|
|
"0x03" : "0x1395",
|
|
"0x04" : "0x1395",
|
|
"0x05" : "0x1395"
|
|
}
|
|
}
|
|
},
|
|
"pre" :
|
|
{
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"balance" : "100000",
|
|
"//" : "contract main ",
|
|
"//" : "{ ",
|
|
"//" : " uint[32] m_gasUsed; ",
|
|
"//" : " int storage; ",
|
|
"//" : " function run() returns (bool) ",
|
|
"//" : " { ",
|
|
"//" : " uint startgas = msg.gas; ",
|
|
"//" : " ",
|
|
"//" : " storage = 1; //zero to non zero ",
|
|
"//" : " m_gasUsed[0] = startgas - msg.gas; ",
|
|
"//" : " startgas = msg.gas; ",
|
|
"//" : " ",
|
|
"//" : " storage = 2; //non zero to non zero ",
|
|
"//" : " m_gasUsed[1] = startgas - msg.gas; ",
|
|
"//" : " startgas = msg.gas; ",
|
|
"//" : " ",
|
|
"//" : " storage = 2; //non zero to same non zero ",
|
|
"//" : " m_gasUsed[2] = startgas - msg.gas; ",
|
|
"//" : " startgas = msg.gas; ",
|
|
"//" : " ",
|
|
"//" : " storage = 24784793845734; //non zero to huge non zero ",
|
|
"//" : " m_gasUsed[3] = startgas - msg.gas; ",
|
|
"//" : " startgas = msg.gas; ",
|
|
"//" : " ",
|
|
"//" : " storage = 2; //huge non zero to non zero ",
|
|
"//" : " m_gasUsed[4] = startgas - msg.gas; ",
|
|
"//" : " startgas = msg.gas; ",
|
|
"//" : " ",
|
|
"//" : " storage = 0; //non zero to zero ",
|
|
"//" : " m_gasUsed[5] = startgas - msg.gas; ",
|
|
"//" : " startgas = msg.gas; ",
|
|
"//" : " ",
|
|
"//" : " return true; ",
|
|
"//" : " } ",
|
|
"//" : "} ",
|
|
"code" : "0x7c01000000000000000000000000000000000000000000000000000000006000350463c04062268114602d57005b6033603d565b8060005260206000f35b600060005a600160205590505a81036000555a600260205590505a81036001555a600260205590505a81036002555a65168aa8d53fe660205590505a81036003555a600260205590505a81036004555a600060205590505a81036005555a5060019291505056",
|
|
"nonce" : "0",
|
|
"storage" : {
|
|
}
|
|
},
|
|
"a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
|
|
"balance" : "50000000",
|
|
"nonce" : "0",
|
|
"code" : "",
|
|
"storage": {}
|
|
}
|
|
},
|
|
"transaction" :
|
|
{
|
|
"data" : "run()",
|
|
"data" : "0xc0406226",
|
|
"gasLimit" : "35000000",
|
|
"gasPrice" : "1",
|
|
"nonce" : "0",
|
|
"secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8",
|
|
"to" : "095e7baea6a6c7c4c2dfeb977efac326af552d87",
|
|
"value" : "0"
|
|
}
|
|
},
|
|
|
|
"TestCryptographicFunctions" : {
|
|
"env" : {
|
|
"currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba",
|
|
"currentDifficulty" : "45678256",
|
|
"currentGasLimit" : "1000000000000000000000",
|
|
"currentNumber" : "120",
|
|
"currentTimestamp" : 1,
|
|
"previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6"
|
|
},
|
|
"expect" : {
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"storage" : {
|
|
"0x" : "0x01"
|
|
}
|
|
}
|
|
},
|
|
"pre" :
|
|
{
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"balance" : "100000",
|
|
"//" : "contract main ",
|
|
"//" : "{ ",
|
|
"//" : " bool returnValue; ",
|
|
"//" : " function run() returns (bool) ",
|
|
"//" : " { ",
|
|
"//" : " returnValue = testCryptographicFunctions(); ",
|
|
"//" : " return returnValue; ",
|
|
"//" : " } ",
|
|
"//" : " ",
|
|
"//" : " function testCryptographicFunctions() returns (bool res) ",
|
|
"//" : " { ",
|
|
"//" : " res = true; ",
|
|
"//" : " if (sha3('teststring') != 0x43c4b4524adb81e4e9a5c4648a98e9d320e3908ac5b6c889144b642cd08ae16d) ",
|
|
"//" : " return false; ",
|
|
"//" : " ",
|
|
"//" : " if (sha256('teststring') != 0x3c8727e019a42b444667a587b6001251becadabbb36bfed8087a92c18882d111) ",
|
|
"//" : " return false; ",
|
|
"//" : " ",
|
|
"//" : " if (ripemd160('teststring') != 0xcd566972b5e50104011a92b59fa8e0b1234851ae) ",
|
|
"//" : " return false; ",
|
|
"//" : " ",
|
|
"//" : " if (ecrecover(0x18c547e4f7b0f325ad1e56f57e26c745b09a3e503d86e00e5255ff7f715d3d1c, ",
|
|
"//" : " 28, 0x73b1693892219d736caba55bdb67216e485557ea6b6af75f37096c9aa6a5a75f, ",
|
|
"//" : " 0xeeb940b1d03b21e36b0e47e79769f095fe2ab855bd91e3a38756b7d75a9c4549) ",
|
|
"//" : " != 0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b) ",
|
|
"//" : " return false; ",
|
|
"//" : " } ",
|
|
"//" : "} ",
|
|
"code" : "0x6000357c010000000000000000000000000000000000000000000000000000000090048063c04062261461003a578063e0a9fd281461004c57005b61004261005e565b8060005260206000f35b610054610099565b8060005260206000f35b6000610068610099565b600060006101000a81548160ff02191690830217905550600060009054906101000a900460ff169050610096565b90565b60006001905080507f43c4b4524adb81e4e9a5c4648a98e9d320e3908ac5b6c889144b642cd08ae16d60010260407f74657374737472696e67000000000000000000000000000000000000000000008152600a016040900360402014156100ff57610108565b600090506102ec565b7f3c8727e019a42b444667a587b6001251becadabbb36bfed8087a92c18882d11160010260026020600060007f74657374737472696e67000000000000000000000000000000000000000000008152600a0160006000856161da5a03f161016b57005b50600051141561017a57610183565b600090506102ec565b73cd566972b5e50104011a92b59fa8e0b1234851ae6c010000000000000000000000000260036020600060007f74657374737472696e67000000000000000000000000000000000000000000008152600a0160006000856161da5a03f16101e657005b506000516c010000000000000000000000000214156102045761020d565b600090506102ec565b73a94f5374fce5edbc8e2a8697c15331677e6ebf0b60016020600060007f18c547e4f7b0f325ad1e56f57e26c745b09a3e503d86e00e5255ff7f715d3d1c6001028152602001601c81526020017f73b1693892219d736caba55bdb67216e485557ea6b6af75f37096c9aa6a5a75f60010281526020017feeb940b1d03b21e36b0e47e79769f095fe2ab855bd91e3a38756b7d75a9c4549600102815260200160006000856161da5a03f16102bd57005b5060005173ffffffffffffffffffffffffffffffffffffffff1614156102e2576102eb565b600090506102ec565b5b9056",
|
|
"nonce" : "0",
|
|
"storage" : {
|
|
}
|
|
},
|
|
"a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
|
|
"balance" : "50000000",
|
|
"nonce" : "0",
|
|
"code" : "",
|
|
"storage": {}
|
|
}
|
|
},
|
|
"transaction" :
|
|
{
|
|
"data" : "run()",
|
|
"data" : "0xc0406226",
|
|
"gasLimit" : "35000000",
|
|
"gasPrice" : "1",
|
|
"nonce" : "0",
|
|
"secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8",
|
|
"to" : "095e7baea6a6c7c4c2dfeb977efac326af552d87",
|
|
"value" : "100"
|
|
}
|
|
},
|
|
|
|
"TestStructuresAndVariabless" : {
|
|
"env" : {
|
|
"currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba",
|
|
"currentDifficulty" : "45678256",
|
|
"currentGasLimit" : "1000000000000000000000",
|
|
"currentNumber" : "120",
|
|
"currentTimestamp" : 1,
|
|
"previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6"
|
|
},
|
|
"expect" : {
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"storage" : {
|
|
"0x" : "0x01",
|
|
"0x01" : "0xff",
|
|
"0x02" : "0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b",
|
|
"0x03" : "0xff",
|
|
"0x04" : "0x676c6f62616c2064617461203332206c656e67746820737472696e6700000000",
|
|
"0x05b8ccbb9d4d8fb16ea74ce3c29a41f1b461fbdaff4714a0d9a8eb05499746bc" : "0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b"
|
|
}
|
|
}
|
|
},
|
|
"pre" :
|
|
{
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"balance" : "100000",
|
|
"//" : "contract main ",
|
|
"//" : "{ ",
|
|
"//" : " struct StructTest ",
|
|
"//" : " { ",
|
|
"//" : " address addr; ",
|
|
"//" : " int amount; ",
|
|
"//" : " bytes32 str; ",
|
|
"//" : " mapping (uint => address) funders; ",
|
|
"//" : " } ",
|
|
"//" : " ",
|
|
"//" : " bool returnValue; ",
|
|
"//" : " int globalValue; ",
|
|
"//" : " StructTest globalData; ",
|
|
"//" : " function run() returns (bool) ",
|
|
"//" : " { ",
|
|
"//" : " globalValue = 255; ",
|
|
"//" : " globalData.addr = 0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b; ",
|
|
"//" : " globalData.amount = 255; ",
|
|
"//" : " globalData.str = 'global data 32 length string'; ",
|
|
"//" : " globalData.funders[0] = 0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b; ",
|
|
"//" : " returnValue = testStructuresAndVariabless(); ",
|
|
"//" : " return returnValue; ",
|
|
"//" : " } ",
|
|
"//" : " ",
|
|
"//" : " function testStructuresAndVariabless() returns (bool res) ",
|
|
"//" : " { ",
|
|
"//" : " res = true; ",
|
|
"//" : " if (globalValue != 255) ",
|
|
"//" : " return false; ",
|
|
"//" : " ",
|
|
"//" : " if (globalValue != globalData.amount) ",
|
|
"//" : " return false; ",
|
|
"//" : " ",
|
|
"//" : " if (globalData.addr != 0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b) ",
|
|
"//" : " return false; ",
|
|
"//" : " ",
|
|
"//" : " if (globalData.str != 'global data 32 length string') ",
|
|
"//" : " return false; ",
|
|
"//" : " ",
|
|
"//" : " if (globalData.funders[0] != 0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b) ",
|
|
"//" : " return false; ",
|
|
"//" : " } ",
|
|
"//" : "} ",
|
|
"code" : "0x7c010000000000000000000000000000000000000000000000000000000060003504632a9afb838114610039578063c04062261461004b57005b61004161005d565b8060005260206000f35b61005361016c565b8060005260206000f35b600160ff8154141561006e57610076565b506000610169565b60015460035414156100875761008f565b506000610169565b73a94f5374fce5edbc8e2a8697c15331677e6ebf0b73ffffffffffffffffffffffffffffffffffffffff60016002540481161614156100cd576100d5565b506000610169565b7f676c6f62616c2064617461203332206c656e67746820737472696e670000000060045414156101045761010c565b506000610169565b6005600080815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673a94f5374fce5edbc8e2a8697c15331677e6ebf0b141561016057610168565b506000610169565b5b90565b600060ff806001555073a94f5374fce5edbc8e2a8697c15331677e6ebf0b6002805473ffffffffffffffffffffffffffffffffffffffff1916821790555060ff80600355507f676c6f62616c2064617461203332206c656e67746820737472696e6700000000806004555073a94f5374fce5edbc8e2a8697c15331677e6ebf0b6005600080815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff0219169083021790555061022f61005d565b600060006101000a81548160ff0219169083021790555060ff6001600054041690509056",
|
|
"nonce" : "0",
|
|
"storage" : {
|
|
}
|
|
},
|
|
"a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
|
|
"balance" : "1000000",
|
|
"nonce" : "0",
|
|
"code" : "",
|
|
"storage": {}
|
|
}
|
|
},
|
|
"transaction" :
|
|
{
|
|
"data" : "run()",
|
|
"data" : "0xc0406226",
|
|
"gasLimit" : "350000",
|
|
"gasPrice" : "1",
|
|
"nonce" : "0",
|
|
"secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8",
|
|
"to" : "095e7baea6a6c7c4c2dfeb977efac326af552d87",
|
|
"value" : "100"
|
|
}
|
|
},
|
|
|
|
"TestBlockAndTransactionProperties" : {
|
|
"env" : {
|
|
"currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba",
|
|
"currentDifficulty" : "45678256",
|
|
"currentGasLimit" : "1000000000000000000000",
|
|
"currentNumber" : "120",
|
|
"currentTimestamp" : 1,
|
|
"previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6"
|
|
},
|
|
"expect" : {
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"storage" : {
|
|
"0x" : "0x01"
|
|
}
|
|
}
|
|
},
|
|
"pre" :
|
|
{
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"balance" : "100000",
|
|
"//" : "contract main ",
|
|
"//" : "{ ",
|
|
"//" : " bool returnValue; ",
|
|
"//" : " function run() returns (bool) ",
|
|
"//" : " { ",
|
|
"//" : " returnValue = testBlockAndTransactionProperties(); ",
|
|
"//" : " return returnValue; ",
|
|
"//" : " } ",
|
|
"//" : " ",
|
|
"//" : " function testBlockAndTransactionProperties() returns (bool res) ",
|
|
"//" : " { ",
|
|
"//" : " res = true; ",
|
|
"//" : " if (block.coinbase != 0x2adc25665018aa1fe0e6bc666dac8fc2697ff9ba) ",
|
|
"//" : " return false; ",
|
|
"//" : " ",
|
|
"//" : " if (block.difficulty != 45678256) ",
|
|
"//" : " return false; ",
|
|
"//" : " ",
|
|
"//" : " if (block.gaslimit != 1000000000000000000000) ",
|
|
"//" : " return false; ",
|
|
"//" : " ",
|
|
"//" : " if (block.number != 120) ",
|
|
"//" : " return false; ",
|
|
"//" : " ",
|
|
"//" : " //try to call this ",
|
|
"//" : " block.blockhash(120); ",
|
|
"//" : " block.timestamp; ",
|
|
"//" : " msg.gas; ",
|
|
"//" : " ",
|
|
"//" : " if (msg.sender != 0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b) ",
|
|
"//" : " return false; ",
|
|
"//" : " ",
|
|
"//" : " if (msg.value != 100) ",
|
|
"//" : " return false; ",
|
|
"//" : " ",
|
|
"//" : " if (tx.gasprice != 1) ",
|
|
"//" : " return false; ",
|
|
"//" : " ",
|
|
"//" : " if (tx.origin != 0xa94f5374fce5edbc8e2a8697c15331677e6ebf0b) ",
|
|
"//" : " return false; ",
|
|
"//" : " ",
|
|
"//" : " } ",
|
|
"//" : "} ",
|
|
"code" : "0x7c01000000000000000000000000000000000000000000000000000000006000350463c04062268114610039578063e97384dc1461004b57005b61004161005d565b8060005260206000f35b61005361008c565b8060005260206000f35b600061006761008c565b600060006101000a81548160ff0219169083021790555060ff60016000540416905090565b6001732adc25665018aa1fe0e6bc666dac8fc2697ff9ba73ffffffffffffffffffffffffffffffffffffffff411614156100c5576100cd565b5060006101c7565b446302b8feb014156100de576100e6565b5060006101c7565b45683635c9adc5dea0000014156100fc57610104565b5060006101c7565b43607814156101125761011a565b5060006101c7565b5a503373ffffffffffffffffffffffffffffffffffffffff1673a94f5374fce5edbc8e2a8697c15331677e6ebf0b14156101535761015b565b5060006101c7565b346064141561016957610171565b5060006101c7565b3a6001141561017f57610187565b5060006101c7565b3273ffffffffffffffffffffffffffffffffffffffff1673a94f5374fce5edbc8e2a8697c15331677e6ebf0b14156101be576101c6565b5060006101c7565b5b9056",
|
|
"nonce" : "0",
|
|
"storage" : {
|
|
}
|
|
},
|
|
"a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
|
|
"balance" : "1000000",
|
|
"nonce" : "0",
|
|
"code" : "",
|
|
"storage": {}
|
|
}
|
|
},
|
|
"transaction" :
|
|
{
|
|
"data" : "run()",
|
|
"data" : "0xc0406226",
|
|
"gasLimit" : "350000",
|
|
"gasPrice" : "1",
|
|
"nonce" : "0",
|
|
"secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8",
|
|
"to" : "095e7baea6a6c7c4c2dfeb977efac326af552d87",
|
|
"value" : "100"
|
|
}
|
|
},
|
|
|
|
"TestContractSuicide" : {
|
|
"env" : {
|
|
"currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba",
|
|
"currentDifficulty" : "45678256",
|
|
"currentGasLimit" : "100000000",
|
|
"currentNumber" : "0",
|
|
"currentTimestamp" : 1,
|
|
"previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6"
|
|
},
|
|
"expect" : {
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"nonce" : "1",
|
|
"storage" : {
|
|
"0x" : "0x01"
|
|
}
|
|
}
|
|
},
|
|
"pre" :
|
|
{
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"balance" : "100000",
|
|
"//": "contract TestContract ",
|
|
"//": "{ ",
|
|
"//": " function testMethod() returns (int res) ",
|
|
"//": " { ",
|
|
"//": " return 225; ",
|
|
"//": " } ",
|
|
"//": " ",
|
|
"//": " function destroy(address sendFoundsTo) ",
|
|
"//": " { ",
|
|
"//": " suicide(sendFoundsTo); ",
|
|
"//": " } ",
|
|
"//": "} ",
|
|
"//": "contract main ",
|
|
"//": "{ ",
|
|
"//": " bool returnValue; ",
|
|
"//": " function run() returns (bool) ",
|
|
"//": " { ",
|
|
"//": " returnValue = testContractSuicide(); ",
|
|
"//": " return returnValue; ",
|
|
"//": " } ",
|
|
"//": " ",
|
|
"//": " function testContractSuicide() returns (bool res) ",
|
|
"//": " { ",
|
|
"//": " TestContract a = new TestContract(); ",
|
|
"//": " a.destroy(block.coinbase); ",
|
|
"//": " if (a.testMethod() == 225) //we should be able to call a contract ",
|
|
"//": " return true; ",
|
|
"//": " return false; ",
|
|
"//": " } ",
|
|
"//": "} ",
|
|
"code" : "0x7c01000000000000000000000000000000000000000000000000000000006000350463a60eedda8114610039578063c04062261461004b57005b61004161005d565b8060005260206000f35b61005361015a565b8060005260206000f35b60006000608161018a600039608160006000f0905073ffffffffffffffffffffffffffffffffffffffff811662f55d9d6000807ef55d9d00000000000000000000000000000000000000000000000000000000825260044173ffffffffffffffffffffffffffffffffffffffff168152602001600060008660325a03f16100e057005b505073ffffffffffffffffffffffffffffffffffffffff811663b9c3d0a5602060007fb9c3d0a50000000000000000000000000000000000000000000000000000000081526004600060008660325a03f161013757005b505060005160e11461014857610151565b60019150610156565b600091505b5090565b600061016461005d565b600060006101000a81548160ff0219169083021790555060ff600160005404169050905600607580600c6000396000f3007c01000000000000000000000000000000000000000000000000000000006000350462f55d9d81146036578063b9c3d0a514604557005b603f600435605a565b60006000f35b604b6055565b8060005260206000f35b60e190565b8073ffffffffffffffffffffffffffffffffffffffff16ff5056",
|
|
"nonce" : "0",
|
|
"storage" : {
|
|
}
|
|
},
|
|
"a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
|
|
"balance" : "1000000",
|
|
"nonce" : "0",
|
|
"code" : "",
|
|
"storage": {}
|
|
}
|
|
},
|
|
"transaction" :
|
|
{
|
|
"data" : "run()",
|
|
"data" : "0xc0406226",
|
|
"gasLimit" : "350000",
|
|
"gasPrice" : "1",
|
|
"nonce" : "0",
|
|
"secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8",
|
|
"to" : "095e7baea6a6c7c4c2dfeb977efac326af552d87",
|
|
"value" : "1"
|
|
}
|
|
},
|
|
|
|
"TestContractInteraction" : {
|
|
"env" : {
|
|
"currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba",
|
|
"currentDifficulty" : "45678256",
|
|
"currentGasLimit" : "100000000",
|
|
"currentNumber" : "0",
|
|
"currentTimestamp" : 1,
|
|
"previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6"
|
|
},
|
|
"expect" : {
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"nonce" : "1",
|
|
"storage" : {
|
|
"0x" : "0x01"
|
|
}
|
|
}
|
|
},
|
|
"pre" :
|
|
{
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"balance" : "100000",
|
|
"//": "contract TestContract ",
|
|
"//": "{ ",
|
|
"//": " function testMethod() returns (int res) ",
|
|
"//": " { ",
|
|
"//": " return 225; ",
|
|
"//": " } ",
|
|
"//": " ",
|
|
"//": " function destroy(address sendFoundsTo) ",
|
|
"//": " { ",
|
|
"//": " suicide(sendFoundsTo); ",
|
|
"//": " } ",
|
|
"//": "} ",
|
|
"//": "contract main ",
|
|
"//": "{ ",
|
|
"//": " bool returnValue; ",
|
|
"//": " function run() returns (bool) ",
|
|
"//": " { ",
|
|
"//": " returnValue = testContractInteraction(); ",
|
|
"//": " return returnValue; ",
|
|
"//": " } ",
|
|
"//": " ",
|
|
"//" : " function testContractInteraction() returns (bool res) ",
|
|
"//" : " { ",
|
|
"//" : " TestContract a = new TestContract(); ",
|
|
"//" : " if (a.testMethod() == 225) ",
|
|
"//" : " return true; ",
|
|
"//" : " return false; ",
|
|
"//" : " } ",
|
|
"//": "} ",
|
|
"code" : "0x7c01000000000000000000000000000000000000000000000000000000006000350463c04062268114610039578063ed973fe91461004b57005b6100416100ea565b8060005260206000f35b61005361005d565b8060005260206000f35b60006000608161011a600039608160006000f0905073ffffffffffffffffffffffffffffffffffffffff811663b9c3d0a5602060007fb9c3d0a50000000000000000000000000000000000000000000000000000000081526004600060008660325a03f16100c757005b505060005160e1146100d8576100e1565b600191506100e6565b600091505b5090565b60006100f461005d565b600060006101000a81548160ff0219169083021790555060ff600160005404169050905600607580600c6000396000f3007c01000000000000000000000000000000000000000000000000000000006000350462f55d9d81146036578063b9c3d0a514604557005b603f6004356055565b60006000f35b604b6070565b8060005260206000f35b8073ffffffffffffffffffffffffffffffffffffffff16ff50565b60e19056",
|
|
"nonce" : "0",
|
|
"storage" : {
|
|
}
|
|
},
|
|
"a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
|
|
"balance" : "1000000",
|
|
"nonce" : "0",
|
|
"code" : "",
|
|
"storage": {}
|
|
}
|
|
},
|
|
"transaction" :
|
|
{
|
|
"data" : "run()",
|
|
"data" : "0xc0406226",
|
|
"gasLimit" : "350000",
|
|
"gasPrice" : "1",
|
|
"nonce" : "0",
|
|
"secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8",
|
|
"to" : "095e7baea6a6c7c4c2dfeb977efac326af552d87",
|
|
"value" : "1"
|
|
}
|
|
},
|
|
|
|
"TestKeywords" : {
|
|
"env" : {
|
|
"currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba",
|
|
"currentDifficulty" : "45678256",
|
|
"currentGasLimit" : "100000000",
|
|
"currentNumber" : "0",
|
|
"currentTimestamp" : 1,
|
|
"previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6"
|
|
},
|
|
"expect" : {
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"storage" : {
|
|
"0x" : "0x01"
|
|
}
|
|
}
|
|
},
|
|
"pre" :
|
|
{
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"balance" : "100000",
|
|
"//": "contract main ",
|
|
"//": "{ ",
|
|
"//": " bool returnValue; ",
|
|
"//": " function run() returns (bool) ",
|
|
"//": " { ",
|
|
"//": " returnValue = testKeywords(); ",
|
|
"//": " return returnValue; ",
|
|
"//": " } ",
|
|
"//": " ",
|
|
"//": " function testKeywords() returns (bool res) ",
|
|
"//": " { ",
|
|
"//": " //some simple checks for the if statemnt ",
|
|
"//": " //if, else, while, for, break, continue, return ",
|
|
"//": " int i = 0; ",
|
|
"//": " res = false; ",
|
|
"//": " ",
|
|
"//": " if (i == 0) ",
|
|
"//": " { ",
|
|
"//": " if( i <= -25) ",
|
|
"//": " { ",
|
|
"//": " return false; ",
|
|
"//": " } ",
|
|
"//": " else ",
|
|
"//": " { ",
|
|
"//": " while(i < 10) ",
|
|
"//": " i++; ",
|
|
"//": " ",
|
|
"//": " if (i == 10) ",
|
|
"//": " { ",
|
|
"//": " for(var j=10; j>0; j--) ",
|
|
"//": " { ",
|
|
"//": " i--; ",
|
|
"//": " } ",
|
|
"//": " } ",
|
|
"//": " } ",
|
|
"//": " } ",
|
|
"//": " ",
|
|
"//": " if (i == 0) ",
|
|
"//": " return true; ",
|
|
"//": " ",
|
|
"//": " return false; ",
|
|
"//": " } ",
|
|
"//": "} ",
|
|
"code" : "0x7c01000000000000000000000000000000000000000000000000000000006000350463380e439681146037578063c040622614604757005b603d6084565b8060005260206000f35b604d6057565b8060005260206000f35b6000605f6084565b600060006101000a81548160ff0219169083021790555060ff60016000540416905090565b6000808160011560cd575b600a82121560a157600190910190608f565b81600a1460ac5760c9565b50600a5b60008160ff16111560c85760019182900391900360b0565b5b60d5565b6000925060ed565b8160001460e05760e8565b6001925060ed565b600092505b50509056",
|
|
"nonce" : "0",
|
|
"storage" : {
|
|
}
|
|
},
|
|
"a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
|
|
"balance" : "1000000",
|
|
"nonce" : "0",
|
|
"code" : "",
|
|
"storage": {}
|
|
}
|
|
},
|
|
"transaction" :
|
|
{
|
|
"data" : "run()",
|
|
"data" : "0xc0406226",
|
|
"gasLimit" : "350000",
|
|
"gasPrice" : "1",
|
|
"nonce" : "0",
|
|
"secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8",
|
|
"to" : "095e7baea6a6c7c4c2dfeb977efac326af552d87",
|
|
"value" : "1"
|
|
}
|
|
},
|
|
|
|
"CreateContractFromMethod" : {
|
|
"env" : {
|
|
"currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba",
|
|
"currentDifficulty" : "45678256",
|
|
"currentGasLimit" : "100000000",
|
|
"currentNumber" : "0",
|
|
"currentTimestamp" : 1,
|
|
"previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6"
|
|
},
|
|
"expect" : {
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"nonce" : "1"
|
|
},
|
|
"d2571607e241ecf590ed94b12d87c94babe36db6" : {
|
|
"balance" : "0",
|
|
"code" : "0x60003560e060020a90048062f55d9d14601e578063b9c3d0a514602d57005b60276004356046565b60006000f35b6033603d565b8060005260206000f35b600060e1905090565b80600160a060020a0316ff5056",
|
|
"nonce" : "0",
|
|
"storage" : {
|
|
}
|
|
}
|
|
},
|
|
"pre" :
|
|
{
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"balance" : "100000",
|
|
"//": "contract TestContract ",
|
|
"//": "{ ",
|
|
"//": " function testMethod() returns (int res) ",
|
|
"//": " { ",
|
|
"//": " return 225; ",
|
|
"//": " } ",
|
|
"//": " ",
|
|
"//": " function destroy(address sendFoundsTo) ",
|
|
"//": " { ",
|
|
"//": " suicide(sendFoundsTo); ",
|
|
"//": " } ",
|
|
"//": "} ",
|
|
"//": " ",
|
|
"//": "contract main ",
|
|
"//": "{ ",
|
|
"//": " function run() returns (uint) ",
|
|
"//": " { ",
|
|
"//": " createContractFromMethod(); ",
|
|
"//": " } ",
|
|
"//": " ",
|
|
"//": " function createContractFromMethod() returns (TestContract a) ",
|
|
"//": " { ",
|
|
"//": " a = new TestContract(); ",
|
|
"//": " } ",
|
|
"//": "} ",
|
|
"code" : "0x60003560e060020a900480637ee17e1214601f578063c040622614602b57005b60256047565b60006000f35b6031603b565b8060005260206000f35b600060436047565b5090565b60006060605d600039606060006000f09050905600605480600c6000396000f30060003560e060020a90048062f55d9d14601e578063b9c3d0a514602d57005b60276004356046565b60006000f35b6033603d565b8060005260206000f35b600060e1905090565b80600160a060020a0316ff5056",
|
|
"nonce" : "0",
|
|
"storage" : {
|
|
}
|
|
},
|
|
"a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
|
|
"balance" : "1000000",
|
|
"nonce" : "0",
|
|
"code" : "",
|
|
"storage": {}
|
|
}
|
|
},
|
|
"transaction" :
|
|
{
|
|
"data" : "run()",
|
|
"data" : "0xc0406226",
|
|
"gasLimit" : "350000",
|
|
"gasPrice" : "1",
|
|
"nonce" : "0",
|
|
"secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8",
|
|
"to" : "095e7baea6a6c7c4c2dfeb977efac326af552d87",
|
|
"value" : "1"
|
|
}
|
|
},
|
|
|
|
"CallLowLevelCreatesSolidity" : {
|
|
"env" : {
|
|
"currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba",
|
|
"currentDifficulty" : "45678256",
|
|
"currentGasLimit" : "100000000",
|
|
"currentNumber" : "0",
|
|
"currentTimestamp" : 1,
|
|
"previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6"
|
|
},
|
|
"expect" : {
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"nonce" : "1",
|
|
"storage" : {
|
|
"0x" : "0xe1",
|
|
"0x01" : "0x095e7baea6a6c7c4c2dfeb977efac326af552d87"
|
|
}
|
|
}
|
|
},
|
|
"pre" :
|
|
{
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"balance" : "100000",
|
|
"//": "contract subcaller ",
|
|
"//": "{ ",
|
|
"//": " function init(address a) ",
|
|
"//": " { ",
|
|
"//": " main(a).setdata(225); ",
|
|
"//": " } ",
|
|
"//": "} ",
|
|
"//": " ",
|
|
"//": "contract main ",
|
|
"//": "{ ",
|
|
"//": " uint data; ",
|
|
"//": " address msgsender; ",
|
|
"//": " function run() returns (uint) ",
|
|
"//": " { ",
|
|
"//": " data = 1; ",
|
|
"//": " msgsender = 0x095e7baea6a6c7c4c2dfeb977efac326af552d87; ",
|
|
"//": " subcaller a = new subcaller(); ",
|
|
"//": " a.init(msgsender); ",
|
|
"//": " return data; ",
|
|
"//": " } ",
|
|
"//": " ",
|
|
"//": " function setdata(uint _data) ",
|
|
"//": " { ",
|
|
"//": " data = _data; ",
|
|
"//": " } ",
|
|
"//": "}",
|
|
"code" : "0x60003560e060020a9004806330debb4214610021578063c04062261461003257005b61002c6004356100c7565b60006000f35b61003a610044565b8060005260206000f35b60006000600160008190555073095e7baea6a6c7c4c2dfeb977efac326af552d87600181905550606a6100d2600039606a60006000f0905080600160a060020a03166319ab453c600060008260e060020a026000526004600154600160a060020a03168152602001600060008660325a03f16100bc57005b505060005491505090565b80600081905550505600605e80600c6000396000f30060003560e060020a9004806319ab453c14601557005b601e6004356024565b60006000f35b80600160a060020a03166330debb42600060008260e060020a02600052600460e18152602001600060008660325a03f1605957005b50505056",
|
|
"nonce" : "0",
|
|
"storage" : {
|
|
}
|
|
},
|
|
"a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
|
|
"balance" : "1000000",
|
|
"nonce" : "0",
|
|
"code" : "",
|
|
"storage": {}
|
|
}
|
|
},
|
|
"transaction" :
|
|
{
|
|
"data" : "run()",
|
|
"data" : "0xc0406226",
|
|
"gasLimit" : "350000",
|
|
"gasPrice" : "1",
|
|
"nonce" : "0",
|
|
"secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8",
|
|
"to" : "095e7baea6a6c7c4c2dfeb977efac326af552d87",
|
|
"value" : "1"
|
|
}
|
|
},
|
|
|
|
"CallRecursiveMethods" : {
|
|
"env" : {
|
|
"currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba",
|
|
"currentDifficulty" : "45678256",
|
|
"currentGasLimit" : "100000000",
|
|
"currentNumber" : "0",
|
|
"currentTimestamp" : 1,
|
|
"previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6"
|
|
},
|
|
"expect" : {
|
|
"2adc25665018aa1fe0e6bc666dac8fc2697ff9ba" : {
|
|
"balance" : "60000"
|
|
}
|
|
},
|
|
"pre" :
|
|
{
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"balance" : "100000",
|
|
"//" : "contract recursiveMethods ",
|
|
"//" : "{ ",
|
|
"//" : " function testInfiniteLoop() ",
|
|
"//" : " { ",
|
|
"//" : " while(true){} ",
|
|
"//" : " } ",
|
|
"//" : " ",
|
|
"//" : " function testRecursiveMethods() ",
|
|
"//" : " { ",
|
|
"//" : " testRecursiveMethods2(); ",
|
|
"//" : " } ",
|
|
"//" : " ",
|
|
"//" : " function testRecursiveMethods2() ",
|
|
"//" : " { ",
|
|
"//" : " testRecursiveMethods(); ",
|
|
"//" : " } ",
|
|
"//" : "}",
|
|
"code" : "0x7c01000000000000000000000000000000000000000000000000000000006000350463296df0df811460415780634893d88a14604d578063981a316514605957005b60476065565b60006000f35b6053607a565b60006000f35b605f6072565b60006000f35b5b6001156070576066565b565b6078607a565b565b60806072565b56",
|
|
"nonce" : "0",
|
|
"storage" : {
|
|
}
|
|
},
|
|
"a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
|
|
"balance" : "500000",
|
|
"nonce" : "0",
|
|
"code" : "",
|
|
"storage": {}
|
|
}
|
|
},
|
|
"transaction" :
|
|
{
|
|
"data" : "testRecursiveMethods()",
|
|
"data" : "0x981a3165",
|
|
"gasLimit" : "60000",
|
|
"gasPrice" : "1",
|
|
"nonce" : "0",
|
|
"secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8",
|
|
"to" : "095e7baea6a6c7c4c2dfeb977efac326af552d87",
|
|
"value" : "1"
|
|
}
|
|
},
|
|
|
|
"CallInfiniteLoop" : {
|
|
"env" : {
|
|
"currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba",
|
|
"currentDifficulty" : "45678256",
|
|
"currentGasLimit" : "100000000",
|
|
"currentNumber" : "0",
|
|
"currentTimestamp" : 1,
|
|
"previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6"
|
|
},
|
|
"expect" : {
|
|
"2adc25665018aa1fe0e6bc666dac8fc2697ff9ba" : {
|
|
"balance" : "300000"
|
|
}
|
|
},
|
|
"pre" :
|
|
{
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"balance" : "100000",
|
|
"//" : "contract recursiveMethods ",
|
|
"//" : "{ ",
|
|
"//" : " function testInfiniteLoop() ",
|
|
"//" : " { ",
|
|
"//" : " while(true){} ",
|
|
"//" : " } ",
|
|
"//" : " ",
|
|
"//" : " function testRecursiveMethods() ",
|
|
"//" : " { ",
|
|
"//" : " testRecursiveMethods2(); ",
|
|
"//" : " } ",
|
|
"//" : " ",
|
|
"//" : " function testRecursiveMethods2() ",
|
|
"//" : " { ",
|
|
"//" : " testRecursiveMethods(); ",
|
|
"//" : " } ",
|
|
"//" : "}",
|
|
"code" : "0x60003560e060020a90048063296df0df1460295780634893d88a146035578063981a316514604157005b602f604d565b60006000f35b603b6062565b60006000f35b6047605a565b60006000f35b5b600115605857604e565b565b60606062565b565b6068605a565b56",
|
|
"nonce" : "0",
|
|
"storage" : {
|
|
}
|
|
},
|
|
"a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
|
|
"balance" : "500000",
|
|
"nonce" : "0",
|
|
"code" : "",
|
|
"storage": {}
|
|
}
|
|
},
|
|
"transaction" :
|
|
{
|
|
"data" : "testInfiniteLoop()",
|
|
"data" : "0x296df0df",
|
|
"gasLimit" : "300000",
|
|
"gasPrice" : "1",
|
|
"nonce" : "0",
|
|
"secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8",
|
|
"to" : "095e7baea6a6c7c4c2dfeb977efac326af552d87",
|
|
"value" : "1"
|
|
}
|
|
},
|
|
|
|
"RecursiveCreateContractsCreate4Contracts" : {
|
|
"env" : {
|
|
"currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba",
|
|
"currentDifficulty" : "45678256",
|
|
"currentGasLimit" : "100000000",
|
|
"currentNumber" : "0",
|
|
"currentTimestamp" : 1,
|
|
"previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6"
|
|
},
|
|
"expect" : {
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"nonce" : "3",
|
|
"storage" : {
|
|
"0x" : "0x095e7baea6a6c7c4c2dfeb977efac326af552d87",
|
|
"0x01" : "0x04"
|
|
}
|
|
},
|
|
"5d35480c6e7f8952363fa280a0a96906da981f63" : {
|
|
"balance" : "2"
|
|
},
|
|
"a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
|
|
"nonce" : "1"
|
|
},
|
|
"b88de88b35ecbf3c141e3caae2baf35834d18f63" : {
|
|
"storage" : {
|
|
"0x" : "0x02"
|
|
}
|
|
},
|
|
"c506eeab8810e0b592686a218b889284e45b2c35" : {
|
|
"storage" : {
|
|
"0x" : "0x01"
|
|
}
|
|
},
|
|
"d2571607e241ecf590ed94b12d87c94babe36db6" : {
|
|
"storage" : {
|
|
"0x" : "0x03"
|
|
}
|
|
}
|
|
},
|
|
"pre" :
|
|
{
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"balance" : "1000000000000000000000000000000000",
|
|
"//" : "contract recursiveCreate1 ",
|
|
"//" : "{ ",
|
|
"//" : " uint depp; ",
|
|
"//" : " function recursiveCreate1(address a, uint depth) ",
|
|
"//" : " { ",
|
|
"//" : " depth = depth - 1; ",
|
|
"//" : " depp = depth; ",
|
|
"//" : " if(depth > 0) ",
|
|
"//" : " main(a).create2(depth); ",
|
|
"//" : " } ",
|
|
"//" : "} ",
|
|
"//" : " ",
|
|
"//" : "contract recursiveCreate2 ",
|
|
"//" : "{ ",
|
|
"//" : " uint depp; ",
|
|
"//" : " function recursiveCreate2(address a, uint depth) ",
|
|
"//" : " { ",
|
|
"//" : " depth = depth - 1; ",
|
|
"//" : " depp = depth; ",
|
|
"//" : " if(depth > 0) ",
|
|
"//" : " recursiveCreate1 rec1 = new recursiveCreate1(a, depth); ",
|
|
"//" : " } ",
|
|
"//" : "} ",
|
|
"//" : " ",
|
|
"//" : "contract main ",
|
|
"//" : "{ ",
|
|
"//" : " address maincontract; ",
|
|
"//" : " uint depp; ",
|
|
"//" : " function run(uint depth) ",
|
|
"//" : " { ",
|
|
"//" : " maincontract = 0x095e7baea6a6c7c4c2dfeb977efac326af552d87; ",
|
|
"//" : " depp = depth; ",
|
|
"//" : " recursiveCreate1 rec1 = new recursiveCreate1(maincontract, depth); ",
|
|
"//" : " } ",
|
|
"//" : " ",
|
|
"//" : " function create2(uint depth) ",
|
|
"//" : " { ",
|
|
"//" : " recursiveCreate2 rec2 = new recursiveCreate2(maincontract, depth); ",
|
|
"//" : " address(rec2).send(2); ",
|
|
"//" : " } ",
|
|
"//" : "}",
|
|
"code" : "0x60003560e060020a90048063820b13f614610021578063a444f5e91461003257005b61002c600435610093565b60006000f35b61003d600435610043565b60006000f35b600073095e7baea6a6c7c4c2dfeb977efac326af552d8760008190555081600181905550606b6101ad600039606b600054600160a060020a0316815260200182815260200160006000f090505050565b600060c86100e560003960c8600054600160a060020a0316815260200182815260200160006000f0905080600160a060020a0316600060026000600060006000848787f16100dd57005b50505050505600604060c860043960045160245160006001820391508160008190555060008211602657604c565b606b605d600039606b83600160a060020a0316815260200182815260200160006000f090505b505050600180605c6000396000f300006040606b6004396004516024516001810390508060008190555060008111602457605b565b81600160a060020a031663820b13f6600060008260e060020a026000526004858152602001600060008660325a03f1605857005b50505b5050600180606a6000396000f300006040606b6004396004516024516001810390508060008190555060008111602457605b565b81600160a060020a031663820b13f6600060008260e060020a026000526004858152602001600060008660325a03f1605857005b50505b5050600180606a6000396000f30000",
|
|
"nonce" : "0",
|
|
"storage" : {
|
|
}
|
|
},
|
|
"a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
|
|
"balance" : "5000000",
|
|
"nonce" : "0",
|
|
"code" : "",
|
|
"storage": {}
|
|
}
|
|
},
|
|
"transaction" :
|
|
{
|
|
"data" : "run(uint256)",
|
|
"data" : "0xa444f5e90000000000000000000000000000000000000000000000000000000000000004",
|
|
"gasLimit" : "300000",
|
|
"gasPrice" : "1",
|
|
"nonce" : "0",
|
|
"secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8",
|
|
"to" : "095e7baea6a6c7c4c2dfeb977efac326af552d87",
|
|
"value" : "1"
|
|
}
|
|
},
|
|
|
|
"RecursiveCreateContracts" : {
|
|
"env" : {
|
|
"currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba",
|
|
"currentDifficulty" : "45678256",
|
|
"currentGasLimit" : "100000000",
|
|
"currentNumber" : "0",
|
|
"currentTimestamp" : 1,
|
|
"previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6"
|
|
},
|
|
"expect" : {
|
|
"2adc25665018aa1fe0e6bc666dac8fc2697ff9ba" : {
|
|
"balance" : "300000"
|
|
}
|
|
},
|
|
"pre" :
|
|
{
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"balance" : "1000000000000000000000000000000000",
|
|
"//" : "contract recursiveCreate1 ",
|
|
"//" : "{ ",
|
|
"//" : " uint depp; ",
|
|
"//" : " function recursiveCreate1(address a, uint depth) ",
|
|
"//" : " { ",
|
|
"//" : " depth = depth - 1; ",
|
|
"//" : " depp = depth; ",
|
|
"//" : " if(depth > 0) ",
|
|
"//" : " main(a).create2(depth); ",
|
|
"//" : " } ",
|
|
"//" : "} ",
|
|
"//" : " ",
|
|
"//" : "contract recursiveCreate2 ",
|
|
"//" : "{ ",
|
|
"//" : " uint depp; ",
|
|
"//" : " function recursiveCreate2(address a, uint depth) ",
|
|
"//" : " { ",
|
|
"//" : " depth = depth - 1; ",
|
|
"//" : " depp = depth; ",
|
|
"//" : " if(depth > 0) ",
|
|
"//" : " recursiveCreate1 rec1 = new recursiveCreate1(a, depth); ",
|
|
"//" : " } ",
|
|
"//" : "} ",
|
|
"//" : " ",
|
|
"//" : "contract main ",
|
|
"//" : "{ ",
|
|
"//" : " address maincontract; ",
|
|
"//" : " uint depp; ",
|
|
"//" : " function run(uint depth) ",
|
|
"//" : " { ",
|
|
"//" : " maincontract = 0x095e7baea6a6c7c4c2dfeb977efac326af552d87; ",
|
|
"//" : " depp = depth; ",
|
|
"//" : " recursiveCreate1 rec1 = new recursiveCreate1(maincontract, depth); ",
|
|
"//" : " } ",
|
|
"//" : " ",
|
|
"//" : " function create2(uint depth) ",
|
|
"//" : " { ",
|
|
"//" : " recursiveCreate2 rec2 = new recursiveCreate2(maincontract, depth); ",
|
|
"//" : " address(rec2).send(2); ",
|
|
"//" : " } ",
|
|
"//" : "}",
|
|
"code" : "0x60003560e060020a90048063820b13f614610021578063a444f5e91461003257005b61002c600435610093565b60006000f35b61003d600435610043565b60006000f35b600073095e7baea6a6c7c4c2dfeb977efac326af552d8760008190555081600181905550606b6101ad600039606b600054600160a060020a0316815260200182815260200160006000f090505050565b600060c86100e560003960c8600054600160a060020a0316815260200182815260200160006000f0905080600160a060020a0316600060026000600060006000848787f16100dd57005b50505050505600604060c860043960045160245160006001820391508160008190555060008211602657604c565b606b605d600039606b83600160a060020a0316815260200182815260200160006000f090505b505050600180605c6000396000f300006040606b6004396004516024516001810390508060008190555060008111602457605b565b81600160a060020a031663820b13f6600060008260e060020a026000526004858152602001600060008660325a03f1605857005b50505b5050600180606a6000396000f300006040606b6004396004516024516001810390508060008190555060008111602457605b565b81600160a060020a031663820b13f6600060008260e060020a026000526004858152602001600060008660325a03f1605857005b50505b5050600180606a6000396000f30000",
|
|
"nonce" : "0",
|
|
"storage" : {
|
|
}
|
|
},
|
|
"a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
|
|
"balance" : "5000000",
|
|
"nonce" : "0",
|
|
"code" : "",
|
|
"storage": {}
|
|
}
|
|
},
|
|
"transaction" :
|
|
{
|
|
"data" : "run(uint256)",
|
|
"data" : "0xa444f5e90000000000000000000000000000000000000000000000000000000000000204",
|
|
"gasLimit" : "300000",
|
|
"gasPrice" : "1",
|
|
"nonce" : "0",
|
|
"secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8",
|
|
"to" : "095e7baea6a6c7c4c2dfeb977efac326af552d87",
|
|
"value" : "1"
|
|
}
|
|
},
|
|
|
|
"AmbiguousMethod" : {
|
|
"env" : {
|
|
"currentCoinbase" : "2adc25665018aa1fe0e6bc666dac8fc2697ff9ba",
|
|
"currentDifficulty" : "45678256",
|
|
"currentGasLimit" : "100000000",
|
|
"currentNumber" : "0",
|
|
"currentTimestamp" : 1,
|
|
"previousHash" : "5e20a0453cecd065ea59c37ac63e079ee08998b6045136a8ce6635c7912ec0b6"
|
|
},
|
|
"expect" : {
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"storage" : {
|
|
"0x" : "0x014f"
|
|
}
|
|
}
|
|
},
|
|
"pre" :
|
|
{
|
|
"095e7baea6a6c7c4c2dfeb977efac326af552d87" : {
|
|
"balance" : "100000",
|
|
"//" : "contract contract1 ",
|
|
"//" : "{ ",
|
|
"//" : " uint value; ",
|
|
"//" : " function run() ",
|
|
"//" : " { ",
|
|
"//" : " value = 225; ",
|
|
"//" : " } ",
|
|
"//" : "} ",
|
|
"//" : " ",
|
|
"//" : "contract contract2 ",
|
|
"//" : "{ ",
|
|
"//" : " uint value2; ",
|
|
"//" : " function run() ",
|
|
"//" : " { ",
|
|
"//" : " value2 = 335; ",
|
|
"//" : " } ",
|
|
"//" : "} ",
|
|
"code" : "0x60003560e060020a90048063c040622614601557005b601b6021565b60006000f35b61014f60008190555056",
|
|
"nonce" : "0",
|
|
"storage" : {
|
|
}
|
|
},
|
|
"a94f5374fce5edbc8e2a8697c15331677e6ebf0b" : {
|
|
"balance" : "500000",
|
|
"nonce" : "0",
|
|
"code" : "",
|
|
"storage": {}
|
|
}
|
|
},
|
|
"transaction" :
|
|
{
|
|
"data" : "run()",
|
|
"data" : "0xc0406226",
|
|
"gasLimit" : "300000",
|
|
"gasPrice" : "1",
|
|
"nonce" : "0",
|
|
"secretKey" : "45a915e4d060149eb4365960e6a7a45f334393093061116b197e3240065ff2d8",
|
|
"to" : "095e7baea6a6c7c4c2dfeb977efac326af552d87",
|
|
"value" : "1"
|
|
}
|
|
}
|
|
}
|
|
|