fundContest is expected to deposit the recorded total rewards into a Pot exactly once, after which the Pot holds exactly what contestToTotalRewards declares. The function has no already-funded check, so a second call moves another full totalRewards into the same Pot while contestToTotalRewards remains unchanged. The Pot token balance diverges from the internal accounting, the surplus is either locked with no refund path or becomes the fuel for the repeated-closePot drain (reported separately).
Likelihood: High. A second call to fundContest with the same index succeeds unconditionally; retries, automation or owner error all trigger it, and nothing records that a contest was already funded.
Impact: Medium. The Pot holds more tokens than the protocol accounts for, so rewards are either permanently over-locked or, combined with the closePot accounting bug, drained out of the Pot.
Verified locally with forge 1.7.1 / solc 0.8.28 (no cheatcodes):
The contest is live. Earn rewards by submitting a finding.
Submissions are being reviewed by our AI judge. Results will be available in a few minutes.
View all submissionsThe contest is complete and the rewards are being distributed.