The FeeCollector's claimRewards
function incorrectly resets user reward state by setting it to the total distributed amount instead of tracking claimed rewards, enabling users to claim rewards multiple times.
In FeeCollector.sol
, when users claim rewards, their reward state is reset to totalDistributed
:
The issue arises when:
A user claims their rewards
New rewards are distributed (totalDistributed
increases)
User can claim a portion of rewards again because userRewards[user]
is set to the previous totalDistributed
Users can claim the same rewards multiple times
Protocol distributes more rewards than intended
Rewards pool will be depleted faster than designed
Potential economic loss for protocol and other users
Manual Review
Track claimed rewards separately from total distributed rewards:
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.