JOSH.PLAY
/ Sandboxes & Architecture
ChainForge EVM Invariant Breaker
EVM Bytecode · Formal Verification
Explore the project
Project
Initializing System Sandbox…
Behind the experiment
Why this matters: ChainForge EVM Invariant Breaker Deep Dive
Expand
ChainForge EVM Invariant Stepper
OllyDbg Bytecode Debugger
Step through raw opcodes to trigger smart-contract invariant violations.
Target Contract
EulerVault.sol (Block #16817996)
PC · Opcode · Arguments
Assembly Annotation
▶
0x00
PUSH1
0x20
Load calldata offset for attack payload
0x02
CALLDATALOAD
Read donationAmount (150 ETH flashloan)
0x03
DUP1
Duplicate donation value on stack
0x04
PUSH1
0x01
Target slot 0x01: totalCollateral
0x06
SLOAD
Current collateral: 100 ETH
0x07
SUB
Simulate donation drain: 100 - 80 = 20 ETH
0x08
PUSH1
0x01
Storage slot 0x01
0x0a
SSTORE
Mutate totalCollateral = 20 ETH
0x0b
PUSH1
0x02
Target slot 0x02: totalBorrowed
0x0d
SLOAD
Current debt: 150 ETH
0x0e
LT
Evaluate Invariant: (20 < 150) => True (Violation!)
0x0f
JUMPI
0x1c
Jump to liquidation bypass routine
0x11
REVERT
Safeguard triggered: Invariant breach
Step Single (F7)
Autonomous Fuzz
Mathematical Invariant Watcher
INVARIANT SATISFIED
Assertion Condition:
collateral >= borrowed
Total Collateral (Slot 0x01):
100 ETH
Total Borrowed (Slot 0x02):
150 ETH
Live EVM Call Stack
Depth: 1
[SP+0]
0x0000000000000000000000000000000000000064
[SP+1]
0x0000000000000000000000000000000000000096
[SP+2]
0x0000000000000000000000000000000000000001