The claimAllRewards function is vulnerable to a reentrancy attack, allowing an attacker to drain more funds than they are entitled to.
The claimAllRewards function sends Ether to the caller before updating the state. This allows the attacker to call the function again before their rewards are cleared, potentially draining the contract of more Ether than intended.
High. An attacker could potentially drain all the Ether from the contract, far exceeding their legitimate rewards.
Manual code review.
Implement the checks-effects-interactions pattern:
First, calculate the total value
Then, delete the rewards
Finally, transfer the Ether
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.