Zero-Amount Buys in Snow::buySnow
Allow Users to Reset s_earnTimer and Block Earn Rewards
The buySnow
function updates s_earnTimer
even when amount == 0
. This allows users to repeatedly call buySnow(0)
to reset the cooldown timer for earnSnow()
.
As a result, any user — or malicious actor — could block others from minting Snow via earn rewards, since earnSnow()
checks this timer:
This effectively enables a denial-of-earn-reward attack, making farming unreliable or entirely inaccessible.
Likelihood:
Anyone can call buySnow(0)
at any time, even without paying fees.
Impact:
Completely breaks the reward earning mechanism.
Prevent zero-amount buys completely:
When buySnow is successfully called, the global timer is reset. This inadvertently affects the earning of snow as that particular action also depends on the global timer.
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.