-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
bugSomething isn't workingSomething isn't working
Description
$ forge test -vvv --match-contract Delegation
[β ] Compiling...
No files changed, compilation skipped
Ran 1 test for test/Ethernaut/DelegationExploit.t.sol:DelegationExploit
[FAIL. Reason: assertion failed] testExploit() (gas: 37866)
Logs:
Target contract deployed
Current owner: 0xaE0bDc4eEAC5E950B67C6819B118761CaAF61946
New owner: 0xaE0bDc4eEAC5E950B67C6819B118761CaAF61946
Error: a == b not satisfied [address]
Left: 0xaE0bDc4eEAC5E950B67C6819B118761CaAF61946
Right: 0x5Bf3eeB5560eEACC941C553320999006D27dD42b
Traces:
[37866] DelegationExploit::testExploit()
ββ [2303] Delegation::owner() [staticcall]
β ββ β [Return] deployer: [0xaE0bDc4eEAC5E950B67C6819B118761CaAF61946]
ββ [0] console::log("Current owner: %s", deployer: [0xaE0bDc4eEAC5E950B67C6819B118761CaAF61946]) [staticcall]
β ββ β [Stop]
ββ [0] VM::startPrank(exploiter: [0x5Bf3eeB5560eEACC941C553320999006D27dD42b])
β ββ β [Return]
ββ [4983] Delegation::pwn()
β ββ [0] exploiter::pwn() [delegatecall]
β β ββ β [Stop]
β ββ β [Stop]
ββ [0] VM::stopPrank()
β ββ β [Return]
ββ [303] Delegation::owner() [staticcall]
β ββ β [Return] deployer: [0xaE0bDc4eEAC5E950B67C6819B118761CaAF61946]
ββ [0] console::log("New owner: %s", deployer: [0xaE0bDc4eEAC5E950B67C6819B118761CaAF61946]) [staticcall]
β ββ β [Stop]
ββ emit log(val: "Error: a == b not satisfied [address]")
ββ emit log_named_address(key: " Left", val: deployer: [0xaE0bDc4eEAC5E950B67C6819B118761CaAF61946])
ββ emit log_named_address(key: " Right", val: exploiter: [0x5Bf3eeB5560eEACC941C553320999006D27dD42b])
ββ [0] VM::store(VM: [0x7109709ECfa91a80626fF3989D68f67F5b1DD12D], 0x6661696c65640000000000000000000000000000000000000000000000000000, 0x0000000000000000000000000000000000000000000000000000000000000001)
β ββ β [Return]
ββ β [Stop]
Suite result: FAILED. 0 passed; 1 failed; 0 skipped; finished in 582.42Β΅s (94.83Β΅s CPU time)
Ran 1 test suite in 167.48ms (582.42Β΅s CPU time): 0 tests passed, 1 failed, 0 skipped (1 total tests)
Failing tests:
Encountered 1 failing test in test/Ethernaut/DelegationExploit.t.sol:DelegationExploit
[FAIL. Reason: assertion failed] testExploit() (gas: 37866)
Encountered a total of 1 failing tests, 0 tests succeededReactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working