Not using SafeMath
can lead to overflow & underflow of arithmetic calculations
Functions such as _getMintAmount
, _notifyReward
, _rewardPerToken
, _getVestingRate
, _earned
are performing extensive calculations but no use of safeMath
to prevent overflow and underflow in arithmetic calculations.
The only valid reason for not using SafeMath
is that the design of the system makes it impossible for overflows or underflows to occur. But even in that case, the only way to prove it is with extensive formal verifications, and a mistake in any place of the system could be catastrophic.
Manual review
Consider using using SafeMath
for all calculations and adding a comment to every statement with an arithmetic operation explaining why it is safe. Ideally, these claims would be accompanied by a formal verification.
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.