Root: The earnSnow function uses a single global s_earnTimer variable to track the one-week cooldown period, causing the timer to reset for all users whenever any single user successfully claims Snow tokens.
Impact: Only one user can claim free Snow tokens per week across the entire protocol, as the first successful claim blocks all other users until the next week cycle begins, creating an unfair race condition and denying legitimate claims.
Normal Behavior: Each user should be able to claim 1 free Snow token per week independently, with individual cooldown periods that don't interfere with other users' claiming abilities.
Specific Issue: The global s_earnTimer is shared across all users, so when one user successfully calls earnSnow(), the timer resets and prevents all other users from claiming until another full week passes, effectively limiting the entire protocol to one claim per week instead of one claim per user per week.
Likelihood: High
Every call to earnSnow() triggers this issue as the global timer always updates
Users will naturally compete to be first each week, creating predictable race conditions
The bug affects 100% of users except the single weekly winner, making it immediately noticeable
Impact: High
Denial of Service: Vast majority of users are prevented from accessing their intended weekly Snow token rewards
Unfair Distribution: Protocol favors users with faster transactions/higher gas fees rather than equal access
Economic Loss: Users lose expected token rewards, reducing protocol participation and value
Add the following test to TestSnow.t.sol and run it, the test illustrate the flow that only one user can get rewarded in a week.
Replace the global timer with individual user timers to allow each user to claim Snow tokens independently on their own weekly schedule.
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.