The claimRewards
function in the protocol does not update the lastClaimTime
mapping after a user successfully claims their rewards. This omission allows users to exploit the rewards system in several ways, including rapid repeated claims, front-running reward distribution, bot-driven reward farming, network congestion attacks, and Sybil attacks. These vulnerabilities can lead to unfair reward distribution, depletion of the reward pool, and economic instability within the protocol.
The function fails to update lastClaimTime[user]
after a claim is made, which allows users to claim rewards continuously without any time restriction. The expected behavior is to record the timestamp of the last successful claim to prevent excessive and unfair claims.
Front-running :
Users can monitor on-chain reward distributions and front-run transactions by claiming immediately before and after rewards are added.
This allows them to double-claim rewards unfairly, concentrating funds in the hands of a few actors.
Bot-Driven Reward Farming:
Automated scripts and bots can be programmed to claim rewards every block if there is no time restriction.
This increases gas costs for other users and depletes the protocol’s funds rapidly, leading to an unbalanced and unfair reward system.
Manual review
Modify claimRewards
to update lastClaimTime
after a successful claim and initialize a waiting period for the next claim:
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.