The RAACMinter contract's getUtilizationRate() function incorrectly uses the lending pool's normalized debt (interest index) instead of the actual borrowed amount, resulting in high utilization rates that break the emission rate mechanism.
In the RAACMinter contract:
Example 1: Small Loan
Given:
Actual borrowed = 100 RAAC
Interest index (RAY) = 1e27
Total deposits = 1000 RAAC
Current calculation:
utilizationRate = (1e27 100) / 1000e18
= 1e29 / 1e21
= 100,000,000% (incorrect!)
Expected calculation:
utilizationRate = (100 100) / 1000
= 10% (correct)
Example 2: Medium Loan
Given:
ctual borrowed = 5000 RAAC
Interest index (RAY) = 1.1e27
Total deposits = 10000 RAAC
Current calculation:
utilizationRate = (1.1e27 100) / 10000e18
= 1.1e29 / 1e22
= 110,000,000% (incorrect!)
Expected calculation:
utilizationRate = (5000 100) / 10000
= 50% (correct)
Emission rate mechanism breaks due to extreme utilization rates
Maximum emission rates triggered unnecessarily
Incorrect token distribution
Protocol economics severely impacted
Potential for excessive token inflation
Manual code review
Use actual borrowed amount:
Add validation checks:
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.