# Honest party's move could become invalid when re-org takes place

DisputeGameFactory uses CREATE (nonce-derived) proxy addresses, so a chain reorg can swap game addresses and make an honest challenger's move land in the wrong game, losing their bond.

- Payout: Audit contest
- Severity: medium
- Program: Optimism
- Found by: xuwinnie
- Disclosed: 2024-08-16
- Write-up quality: 7/10
- Original: https://github.com/code-423n4/2024-07-optimism-findings/issues/24
- Library page: https://bugbountylibrary.com/r/c4%3A2024-07-optimism%3AM-09
- Tags: area:web3 domain:web3 impact:funds-loss kind:contest platform:code4rena sev:medium tech:evm tech:solidity technique:incomplete-fix technique:source-review vuln:business-logic

**Target:** FaultDisputeGame / DisputeGameFactory dispute contracts
**Root cause:** Game proxies are deployed with CREATE, so their addresses derive from sender+nonce; a reorg reorders deployments and swaps game addresses. The move() fix only checks the disputed claim hash, not which game/position the move belongs to.
**Steps:**
1. Alice deploys invalid root A -> game P; Bob attacks A with claim B in P; Bob deploys valid root C -> game Q.
2. Alice attacks C with same claim B in Q; Coco defends B with D in Q.
3. Reorg reorders txs so P and Q addresses swap (CREATE nonce-derived).
4. Coco's defend tx now executes against the wrong game P, implying wrong validity and losing her bond.
5. Second scenario: within one game, reorg reorders attack/defend txs so Coco's defend of claim C also implies invalid claim E is valid, losing bond.
**How found:** Reading move() and the factory's clone deployment, noticed the new _claim parameter only binds the disputed claim hash, not game identity/position; reasoned that CREATE nonce-derived addresses plus reorg reordering break that binding.
**Exploitation:** Attacker (colluding with a 'honest' party) uses a helper contract to store claims/indices so their txs don't revert across reordering, then relies on a natural chain reorg to shift honest challengers' moves onto the wrong game/claim, slashing their bonds.
**Insight:** When a fix adds a hash check to bind a call to a target, verify it binds the full context (which contract/instance and position), not just one field; nonce-derived CREATE addresses are reorg-fragile, prefer CREATE2 with deterministic salt.

## Proof of concept (copied exactly from the original report)

**move() signature with added _claim parameter**

```
function move(Claim _disputed, uint256 _challengeIndex, Claim _claim, bool _isAttack) public payable virtual {
```

**Factory clone and create deployment code**

```
proxy_ = IDisputeGame(address(impl).clone(abi.encodePacked(msg.sender, _rootClaim, parentHash, _extraData)));
    ......
    instance := create(value, add(m, add(0x0b, lt(n, 0xffd3))), add(n, 0x37))
```

