Precision loss errors in _calculateInterest function in the Lender contract.
The division is performed before multiplication in the _calculateInterest function. Check this part (the calculation of fees):
It should rather be calculated like this:
The following POC was made (Fuzz-testing):
The above assertion failed. fees2 was always greater than or equal to fees1.
Because of rounding errors, the protocol would miss out on potential fees.
Manual review, fuzz-testing.
Use this calculation instead:
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.