Online Solidity Decompiler

« Decompile another contract

Address

0x7e504539ce260aa4b3060f00a65081c3ce7ca8d4 [etherscan.io | etherchain.org]

Public Methods

No public methods detected.

Internal Methods

func_00A5() returns (r0)

Decompilation

This might be constructor bytecode - to get at the deployed contract, go back and remove the constructor prefix, usually up to the next 6060 or 6080.
contract Contract { function main() { memory[0x40:0x60] = 0x80; if (msg.data.length >= 0x04) { var0 = msg.data[0x00:0x20] >> 0xe0; if (var0 != 0x5c60da1b) { goto label_0031; } var1 = msg.value; if (var1) { revert(memory[0x00:0x00]); } var1 = 0x004e; var1 = func_00A5(); var temp3 = memory[0x40:0x60]; memory[temp3:temp3 + 0x20] = var1 & (0x01 << 0xa0) - 0x01; var temp4 = memory[0x40:0x60]; return memory[temp4:temp4 + (temp3 + 0x20) - temp4]; } else if (msg.data.length) { label_0031: var var0 = 0x002f; label_006A: var var1 = 0x00a3; var var2 = storage[0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc] & (0x01 << 0xa0) - 0x01; var temp0 = msg.data.length; memory[0x00:0x00 + temp0] = msg.data[0x00:0x00 + temp0]; var temp1; temp1, memory[0x00:0x00] = address(var2).delegatecall.gas(msg.gas)(memory[0x00:0x00 + msg.data.length]); var temp2 = returndata.length; memory[0x00:0x00 + temp2] = returndata[0x00:0x00 + temp2]; if (!temp1) { revert(memory[0x00:0x00 + returndata.length]); } else { return memory[0x00:0x00 + returndata.length]; } } else { var0 = 0x002f; goto label_006A; } } function func_00A5() returns (var r0) { var var0 = 0x00; var var1 = storage[0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc] & (0x01 << 0xa0) - 0x01; return var1; } }

Disassembly

label_0000: // Inputs[1] { @0007 msg.data.length } 0000 60 PUSH1 0x80 0002 60 PUSH1 0x40 0004 52 MSTORE 0005 60 PUSH1 0x04 0007 36 CALLDATASIZE 0008 10 LT 0009 61 PUSH2 0x0022 000C 57 *JUMPI // Stack delta = +0 // Outputs[1] { @0004 memory[0x40:0x60] = 0x80 } // Block ends with conditional jump to 0x0022, if msg.data.length < 0x04 label_000D: // Incoming jump from 0x000C, if not msg.data.length < 0x04 // Inputs[1] { @000F msg.data[0x00:0x20] } 000D 60 PUSH1 0x00 000F 35 CALLDATALOAD 0010 60 PUSH1 0xe0 0012 1C SHR 0013 80 DUP1 0014 63 PUSH4 0x5c60da1b 0019 14 EQ 001A 61 PUSH2 0x0039 001D 57 *JUMPI // Stack delta = +1 // Outputs[1] { @0012 stack[0] = msg.data[0x00:0x20] >> 0xe0 } // Block ends with conditional jump to 0x0039, if 0x5c60da1b == msg.data[0x00:0x20] >> 0xe0 label_001E: // Incoming jump from 0x001D, if not 0x5c60da1b == msg.data[0x00:0x20] >> 0xe0 001E 61 PUSH2 0x0031 0021 56 *JUMP // Stack delta = +0 // Block ends with unconditional jump to 0x0031 label_0022: // Incoming jump from 0x000C, if msg.data.length < 0x04 // Inputs[1] { @0023 msg.data.length } 0022 5B JUMPDEST 0023 36 CALLDATASIZE 0024 61 PUSH2 0x0031 0027 57 *JUMPI // Stack delta = +0 // Block ends with conditional jump to 0x0031, if msg.data.length label_0028: // Incoming jump from 0x0027, if not msg.data.length 0028 61 PUSH2 0x002f 002B 61 PUSH2 0x006a 002E 56 *JUMP // Stack delta = +1 // Outputs[1] { @0028 stack[0] = 0x002f } // Block ends with unconditional jump to 0x006a 002F 5B JUMPDEST 0030 00 *STOP label_0031: // Incoming jump from 0x0021 // Incoming jump from 0x0027, if msg.data.length 0031 5B JUMPDEST 0032 61 PUSH2 0x002f 0035 61 PUSH2 0x006a 0038 56 *JUMP // Stack delta = +1 // Outputs[1] { @0032 stack[0] = 0x002f } // Block ends with unconditional jump to 0x006a label_0039: // Incoming jump from 0x001D, if 0x5c60da1b == msg.data[0x00:0x20] >> 0xe0 // Inputs[1] { @003A msg.value } 0039 5B JUMPDEST 003A 34 CALLVALUE 003B 80 DUP1 003C 15 ISZERO 003D 61 PUSH2 0x0045 0040 57 *JUMPI // Stack delta = +1 // Outputs[1] { @003A stack[0] = msg.value } // Block ends with conditional jump to 0x0045, if !msg.value label_0041: // Incoming jump from 0x0040, if not !msg.value // Inputs[1] { @0044 memory[0x00:0x00] } 0041 60 PUSH1 0x00 0043 80 DUP1 0044 FD *REVERT // Stack delta = +0 // Outputs[1] { @0044 revert(memory[0x00:0x00]); } // Block terminates label_0045: // Incoming jump from 0x0040, if !msg.value 0045 5B JUMPDEST 0046 50 POP 0047 61 PUSH2 0x004e 004A 61 PUSH2 0x00a5 004D 56 *JUMP // Stack delta = +0 // Outputs[1] { @0047 stack[-1] = 0x004e } // Block ends with call to 0x00a5, returns to 0x004E label_004E: // Incoming return from call to 0x00A5 at 0x004D // Inputs[4] // { // @0051 memory[0x40:0x60] // @005B stack[-1] // @0064 memory[0x40:0x60] // @0069 memory[memory[0x40:0x60]:memory[0x40:0x60] + (0x20 + memory[0x40:0x60]) - memory[0x40:0x60]] // } 004E 5B JUMPDEST 004F 60 PUSH1 0x40 0051 51 MLOAD 0052 60 PUSH1 0x01 0054 60 PUSH1 0x01 0056 60 PUSH1 0xa0 0058 1B SHL 0059 03 SUB 005A 90 SWAP1 005B 91 SWAP2 005C 16 AND 005D 81 DUP2 005E 52 MSTORE 005F 60 PUSH1 0x20 0061 01 ADD 0062 60 PUSH1 0x40 0064 51 MLOAD 0065 80 DUP1 0066 91 SWAP2 0067 03 SUB 0068 90 SWAP1 0069 F3 *RETURN // Stack delta = -1 // Outputs[2] // { // @005E memory[memory[0x40:0x60]:memory[0x40:0x60] + 0x20] = stack[-1] & (0x01 << 0xa0) - 0x01 // @0069 return memory[memory[0x40:0x60]:memory[0x40:0x60] + (0x20 + memory[0x40:0x60]) - memory[0x40:0x60]]; // } // Block terminates label_006A: // Incoming jump from 0x002E // Incoming jump from 0x0038 // Inputs[1] { @0092 storage[0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc] } 006A 5B JUMPDEST 006B 61 PUSH2 0x00a3 006E 61 PUSH2 0x009e 0071 7F PUSH32 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc 0092 54 SLOAD 0093 60 PUSH1 0x01 0095 60 PUSH1 0x01 0097 60 PUSH1 0xa0 0099 1B SHL 009A 03 SUB 009B 16 AND 009C 90 SWAP1 009D 56 *JUMP // Stack delta = +2 // Outputs[2] // { // @006B stack[0] = 0x00a3 // @009C stack[1] = (0x01 << 0xa0) - 0x01 & storage[0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc] // } // Block ends with unconditional jump to 0x009e label_009E: // Incoming jump from 0x009D 009E 5B JUMPDEST 009F 61 PUSH2 0x010c 00A2 56 *JUMP // Stack delta = +0 // Block ends with unconditional jump to 0x010c 00A3 5B JUMPDEST 00A4 56 *JUMP label_00A5: // Incoming call from 0x004D, returns to 0x004E // Inputs[1] { @00CC storage[0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc] } 00A5 5B JUMPDEST 00A6 60 PUSH1 0x00 00A8 61 PUSH2 0x00d8 00AB 7F PUSH32 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc 00CC 54 SLOAD 00CD 60 PUSH1 0x01 00CF 60 PUSH1 0x01 00D1 60 PUSH1 0xa0 00D3 1B SHL 00D4 03 SUB 00D5 16 AND 00D6 90 SWAP1 00D7 56 *JUMP // Stack delta = +2 // Outputs[2] // { // @00A6 stack[0] = 0x00 // @00D6 stack[1] = (0x01 << 0xa0) - 0x01 & storage[0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc] // } // Block ends with unconditional jump to 0x00d8 label_00D8: // Incoming jump from 0x00D7 // Inputs[3] // { // @00D9 stack[-2] // @00D9 stack[-1] // @00DB stack[-3] // } 00D8 5B JUMPDEST 00D9 90 SWAP1 00DA 50 POP 00DB 90 SWAP1 00DC 56 *JUMP // Stack delta = -2 // Outputs[1] { @00DB stack[-3] = stack[-1] } // Block ends with unconditional jump to stack[-3] 00DD 5B JUMPDEST 00DE 90 SWAP1 00DF 56 *JUMP 00E0 5B JUMPDEST 00E1 60 PUSH1 0x60 00E3 61 PUSH2 0x0105 00E6 83 DUP4 00E7 83 DUP4 00E8 60 PUSH1 0x40 00EA 51 MLOAD 00EB 80 DUP1 00EC 60 PUSH1 0x60 00EE 01 ADD 00EF 60 PUSH1 0x40 00F1 52 MSTORE 00F2 80 DUP1 00F3 60 PUSH1 0x27 00F5 81 DUP2 00F6 52 MSTORE 00F7 60 PUSH1 0x20 00F9 01 ADD 00FA 61 PUSH2 0x02cb 00FD 60 PUSH1 0x27 00FF 91 SWAP2 0100 39 CODECOPY 0101 61 PUSH2 0x0130 0104 56 *JUMP 0105 5B JUMPDEST 0106 93 SWAP4 0107 92 SWAP3 0108 50 POP 0109 50 POP 010A 50 POP 010B 56 *JUMP label_010C: // Incoming jump from 0x00A2 // Inputs[9] // { // @010D msg.data.length // @0111 msg.data[0x00:0x00 + msg.data.length] // @0115 msg.data.length // @0118 stack[-1] // @0119 msg.gas // @011A address(stack[-1]).delegatecall.gas(msg.gas)(memory[0x00:0x00 + msg.data.length]) // @011A memory[0x00:0x00 + msg.data.length] // @011B returndata.length // @011F returndata[0x00:0x00 + returndata.length] // } 010C 5B JUMPDEST 010D 36 CALLDATASIZE 010E 60 PUSH1 0x00 0110 80 DUP1 0111 37 CALLDATACOPY 0112 60 PUSH1 0x00 0114 80 DUP1 0115 36 CALLDATASIZE 0116 60 PUSH1 0x00 0118 84 DUP5 0119 5A GAS 011A F4 DELEGATECALL 011B 3D RETURNDATASIZE 011C 60 PUSH1 0x00 011E 80 DUP1 011F 3E RETURNDATACOPY 0120 80 DUP1 0121 80 DUP1 0122 15 ISZERO 0123 61 PUSH2 0x012b 0126 57 *JUMPI // Stack delta = +2 // Outputs[5] // { // @0111 memory[0x00:0x00 + msg.data.length] = msg.data[0x00:0x00 + msg.data.length] // @011A memory[0x00:0x00] = address(stack[-1]).delegatecall.gas(msg.gas)(memory[0x00:0x00 + msg.data.length]) // @011A stack[0] = address(stack[-1]).delegatecall.gas(msg.gas)(memory[0x00:0x00 + msg.data.length]) // @011F memory[0x00:0x00 + returndata.length] = returndata[0x00:0x00 + returndata.length] // @0120 stack[1] = address(stack[-1]).delegatecall.gas(msg.gas)(memory[0x00:0x00 + msg.data.length]) // } // Block ends with conditional jump to 0x012b, if !address(stack[-1]).delegatecall.gas(msg.gas)(memory[0x00:0x00 + msg.data.length]) label_0127: // Incoming jump from 0x0126, if not !address(stack[-1]).delegatecall.gas(msg.gas)(memory[0x00:0x00 + msg.data.length]) // Inputs[2] // { // @0127 returndata.length // @012A memory[0x00:0x00 + returndata.length] // } 0127 3D RETURNDATASIZE 0128 60 PUSH1 0x00 012A F3 *RETURN // Stack delta = +0 // Outputs[1] { @012A return memory[0x00:0x00 + returndata.length]; } // Block terminates label_012B: // Incoming jump from 0x0126, if !address(stack[-1]).delegatecall.gas(msg.gas)(memory[0x00:0x00 + msg.data.length]) // Inputs[2] // { // @012C returndata.length // @012F memory[0x00:0x00 + returndata.length] // } 012B 5B JUMPDEST 012C 3D RETURNDATASIZE 012D 60 PUSH1 0x00 012F FD *REVERT // Stack delta = +0 // Outputs[1] { @012F revert(memory[0x00:0x00 + returndata.length]); } // Block terminates 0130 5B JUMPDEST 0131 60 PUSH1 0x60 0133 60 PUSH1 0x01 0135 60 PUSH1 0x01 0137 60 PUSH1 0xa0 0139 1B SHL 013A 03 SUB 013B 84 DUP5 013C 16 AND 013D 3B EXTCODESIZE 013E 61 PUSH2 0x019d 0141 57 *JUMPI 0142 60 PUSH1 0x40 0144 51 MLOAD 0145 62 PUSH3 0x461bcd 0149 60 PUSH1 0xe5 014B 1B SHL 014C 81 DUP2 014D 52 MSTORE 014E 60 PUSH1 0x20 0150 60 PUSH1 0x04 0152 82 DUP3 0153 01 ADD 0154 52 MSTORE 0155 60 PUSH1 0x26 0157 60 PUSH1 0x24 0159 82 DUP3 015A 01 ADD 015B 52 MSTORE 015C 7F PUSH32 0x416464726573733a2064656c65676174652063616c6c20746f206e6f6e2d636f 017D 60 PUSH1 0x44 017F 82 DUP3 0180 01 ADD 0181 52 MSTORE 0182 65 PUSH6 0x1b9d1c9858dd 0189 60 PUSH1 0xd2 018B 1B SHL 018C 60 PUSH1 0x64 018E 82 DUP3 018F 01 ADD 0190 52 MSTORE 0191 60 PUSH1 0x84 0193 01 ADD 0194 5B JUMPDEST 0195 60 PUSH1 0x40 0197 51 MLOAD 0198 80 DUP1 0199 91 SWAP2 019A 03 SUB 019B 90 SWAP1 019C FD *REVERT 019D 5B JUMPDEST 019E 60 PUSH1 0x00 01A0 80 DUP1 01A1 85 DUP6 01A2 60 PUSH1 0x01 01A4 60 PUSH1 0x01 01A6 60 PUSH1 0xa0 01A8 1B SHL 01A9 03 SUB 01AA 16 AND 01AB 85 DUP6 01AC 60 PUSH1 0x40 01AE 51 MLOAD 01AF 61 PUSH2 0x01b8 01B2 91 SWAP2 01B3 90 SWAP1 01B4 61 PUSH2 0x024b 01B7 56 *JUMP 01B8 5B JUMPDEST 01B9 60 PUSH1 0x00 01BB 60 PUSH1 0x40 01BD 51 MLOAD 01BE 80 DUP1 01BF 83 DUP4 01C0 03 SUB 01C1 81 DUP2 01C2 85 DUP6 01C3 5A GAS 01C4 F4 DELEGATECALL 01C5 91 SWAP2 01C6 50 POP 01C7 50 POP 01C8 3D RETURNDATASIZE 01C9 80 DUP1 01CA 60 PUSH1 0x00 01CC 81 DUP2 01CD 14 EQ 01CE 61 PUSH2 0x01f3 01D1 57 *JUMPI 01D2 60 PUSH1 0x40 01D4 51 MLOAD 01D5 91 SWAP2 01D6 50 POP 01D7 60 PUSH1 0x1f 01D9 19 NOT 01DA 60 PUSH1 0x3f 01DC 3D RETURNDATASIZE 01DD 01 ADD 01DE 16 AND 01DF 82 DUP3 01E0 01 ADD 01E1 60 PUSH1 0x40 01E3 52 MSTORE 01E4 3D RETURNDATASIZE 01E5 82 DUP3 01E6 52 MSTORE 01E7 3D RETURNDATASIZE 01E8 60 PUSH1 0x00 01EA 60 PUSH1 0x20 01EC 84 DUP5 01ED 01 ADD 01EE 3E RETURNDATACOPY 01EF 61 PUSH2 0x01f8 01F2 56 *JUMP 01F3 5B JUMPDEST 01F4 60 PUSH1 0x60 01F6 91 SWAP2 01F7 50 POP 01F8 5B JUMPDEST 01F9 50 POP 01FA 91 SWAP2 01FB 50 POP 01FC 91 SWAP2 01FD 50 POP 01FE 61 PUSH2 0x0208 0201 82 DUP3 0202 82 DUP3 0203 86 DUP7 0204 61 PUSH2 0x0212 0207 56 *JUMP 0208 5B JUMPDEST 0209 96 SWAP7 020A 95 SWAP6 020B 50 POP 020C 50 POP 020D 50 POP 020E 50 POP 020F 50 POP 0210 50 POP 0211 56 *JUMP 0212 5B JUMPDEST 0213 60 PUSH1 0x60 0215 83 DUP4 0216 15 ISZERO 0217 61 PUSH2 0x0221 021A 57 *JUMPI 021B 50 POP 021C 81 DUP2 021D 61 PUSH2 0x0105 0220 56 *JUMP 0221 5B JUMPDEST 0222 82 DUP3 0223 51 MLOAD 0224 15 ISZERO 0225 61 PUSH2 0x0231 0228 57 *JUMPI 0229 82 DUP3 022A 51 MLOAD 022B 80 DUP1 022C 84 DUP5 022D 60 PUSH1 0x20 022F 01 ADD 0230 FD *REVERT 0231 5B JUMPDEST 0232 81 DUP2 0233 60 PUSH1 0x40 0235 51 MLOAD 0236 62 PUSH3 0x461bcd 023A 60 PUSH1 0xe5 023C 1B SHL 023D 81 DUP2 023E 52 MSTORE 023F 60 PUSH1 0x04 0241 01 ADD 0242 61 PUSH2 0x0194 0245 91 SWAP2 0246 90 SWAP1 0247 61 PUSH2 0x0267 024A 56 *JUMP 024B 5B JUMPDEST 024C 60 PUSH1 0x00 024E 82 DUP3 024F 51 MLOAD 0250 61 PUSH2 0x025d 0253 81 DUP2 0254 84 DUP5 0255 60 PUSH1 0x20 0257 87 DUP8 0258 01 ADD 0259 61 PUSH2 0x029a 025C 56 *JUMP 025D 5B JUMPDEST 025E 91 SWAP2 025F 90 SWAP1 0260 91 SWAP2 0261 01 ADD 0262 92 SWAP3 0263 91 SWAP2 0264 50 POP 0265 50 POP 0266 56 *JUMP 0267 5B JUMPDEST 0268 60 PUSH1 0x20 026A 81 DUP2 026B 52 MSTORE 026C 60 PUSH1 0x00 026E 82 DUP3 026F 51 MLOAD 0270 80 DUP1 0271 60 PUSH1 0x20 0273 84 DUP5 0274 01 ADD 0275 52 MSTORE 0276 61 PUSH2 0x0286 0279 81 DUP2 027A 60 PUSH1 0x40 027C 85 DUP6 027D 01 ADD 027E 60 PUSH1 0x20 0280 87 DUP8 0281 01 ADD 0282 61 PUSH2 0x029a 0285 56 *JUMP 0286 5B JUMPDEST 0287 60 PUSH1 0x1f 0289 01 ADD 028A 60 PUSH1 0x1f 028C 19 NOT 028D 16 AND 028E 91 SWAP2 028F 90 SWAP1 0290 91 SWAP2 0291 01 ADD 0292 60 PUSH1 0x40 0294 01 ADD 0295 92 SWAP3 0296 91 SWAP2 0297 50 POP 0298 50 POP 0299 56 *JUMP 029A 5B JUMPDEST 029B 60 PUSH1 0x00 029D 5B JUMPDEST 029E 83 DUP4 029F 81 DUP2 02A0 10 LT 02A1 15 ISZERO 02A2 61 PUSH2 0x02b5 02A5 57 *JUMPI 02A6 81 DUP2 02A7 81 DUP2 02A8 01 ADD 02A9 51 MLOAD 02AA 83 DUP4 02AB 82 DUP3 02AC 01 ADD 02AD 52 MSTORE 02AE 60 PUSH1 0x20 02B0 01 ADD 02B1 61 PUSH2 0x029d 02B4 56 *JUMP 02B5 5B JUMPDEST 02B6 83 DUP4 02B7 81 DUP2 02B8 11 GT 02B9 15 ISZERO 02BA 61 PUSH2 0x02c4 02BD 57 *JUMPI 02BE 60 PUSH1 0x00 02C0 84 DUP5 02C1 84 DUP5 02C2 01 ADD 02C3 52 MSTORE 02C4 5B JUMPDEST 02C5 50 POP 02C6 50 POP 02C7 50 POP 02C8 50 POP 02C9 56 *JUMP 02CA FE *ASSERT 02CB 41 COINBASE 02CC 64 PUSH5 0x6472657373 02D2 3A GASPRICE 02D3 20 SHA3 02D4 6C PUSH13 0x6f772d6c6576656c2064656c65 02E2 67 PUSH8 0x6174652063616c6c 02EB 20 SHA3 02EC 66 PUSH7 0x61696c6564a264 02F4 69 PUSH10 0x7066735822122007dc17 02FF 4B 4B 0300 5B JUMPDEST 0301 68 PUSH9 0x818eda5c7db7ca1afc 030B F9 F9 030C 9D SWAP14 030D 12 SLT 030E C5 C5 030F 0D 0D 0310 C1 C1 0311 68 PUSH9 0x55ea59db8790522bf4 031B B3 B3 031C 64 PUSH5 0x736f6c6343 0322 00 *STOP 0323 08 ADDMOD 0324 07 SMOD 0325 00 *STOP 0326 33 CALLER
Found this site useful?
Donations are greatly appreciated!
ETH: 0xB3F04f0c276fa1177c1779f6E1E156B2738ea392
Contact/hire: [email protected]