The lastClaimTime
variable is updated every time a user calls claimThrone()
. Since each call extends the game by adding a gracePeriod
(typically 1 day), users can perpetually delay the game's end by continuously claiming the throne.
This creates an infinite game loop unless claiming the throne becomes economically unviable. There is no upper bound on game duration, which can lead to the contract never progressing to payout or resolution.
Medium
Likelihood:
The game will continue indefinitely if even one participant keeps claiming the throne within the grace period window.
Impact:
The game may never resolve, breaking core assumptions about winner selection and payout timelines.
Funds in the pot could be locked indefinitely.
Potential DoS on payout logic or platform fee withdrawal.
none
Add maxGameDuration to maintain solvency in the contract
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.