The flagOutcome() function requires the registry to show CORRUPTED state before the moderator can flag a CORRUPTED outcome. However, BattleChain's state machine is one-way terminal, once an agreement reaches PRODUCTION, it can never transition to CORRUPTED. This creates a scenario where in-scope contracts are breached but the moderator has no way to flag the correct outcome.
The contract blindly trusts the agreement-level registry state without accounting for the case where an OOS contract reaches terminal state first (PRODUCTION).
Moderator CANNOT flag correct CORRUPTED outcome. Stakers incorrectly refunded principal + bonus (SURVIVED/EXPIRED).
Pool Setup:
Pool Scope (IS): [ContractA]
Agreement Scope: [ContractA, ContractB] (ContractB = OOS)
Total Staked: 10,000 tokens
Total Bonus: 1,000 tokens
Timeline:
Day 1: Agreement → UNDER_ATTACK
riskWindowStart = Day 1
Day 50: ContractB (OOS) successfully defended
Agreement registry → PRODUCTION ← ONE-WAY TERMINAL
Registry is now LOCKED at PRODUCTION forever
Day 51: ContractA (IS) gets exploited/corrupted
Attacker steals funds from in-scope contract
Day 52: Moderator knows ContractA was breached
Tries to flag correct outcome:
Result:
Moderator only option: flag SURVIVED (wrong outcome)
Allow moderator to flag CORRUPTED outcome when registry shows PRODUCTION, relying on their off-chain judgement (same trust model already used for SURVIVED on CORRUPTED registry):
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.
The contest is complete and the rewards are being distributed.