Normally, after a goodFaith CORRUPTED flag, claimCorrupted is blocked until the attacker's bounty is claimed first (MustClaimBountyFirst gate).
When goodFaith=false, the MustClaimBountyFirst gate is inactive, allowing immediate permissionless drain of the entire pool to recoveryAddress.
The moderator may temporarily flag bad-faith while investigating the breach.
MEV bots monitor flagOutcome events and will front-run any re-flag within the same block.
Impact:
Entire pool value swept to recoveryAddress instantly.
Moderator permanently locked out of re-flagging (claimsStarted = true).
Whitehat bounty impossible — pool has no funds left.
The Foundry test below demonstrates that after a bad-faith CORRUPTED flag, anyone can drain the entire pool via claimCorrupted before the moderator can re-flag to good-faith:
forge test --match-path "test/PoC_BattleChain_Medium.t.sol" -vv --match-test test_M02_BadFaithDrain
All 4 tests PASS (gas: 779,472)
Add a minimum 24-hour cooldown between bad-faith CORRUPTED flag and claimCorrupted to give the moderator a window to re-flag to good-faith.
Mitigation:
Add a minimum 24-hour cooldown between a bad-faith CORRUPTED flag and claimCorrupted:
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
View preliminary resultsAppeals are being carefully reviewed by our judges.
The contest is complete and the rewards are being distributed.