Summary
Vulnerability Details
FeeCollector.sol contract code with comment
* @dev Fixed values used in calculations and validations
* - BASIS_POINTS Percentage calculation base (10000 = 100%)
uint256 public constant BASIS_POINTS = 10000;
that means protocol using BIPs, where 1% == 100 Bips so 100% == 100_00 BIPs
Now,
_initializeFeeTypes()
has following code lines
feeTypes[6] = FeeType({
veRAACShare: 500,
burnShare: 500,
repairShare: 1000,
treasuryShare: 0
});
feeTypes[7] = FeeType({
veRAACShare: 500,
burnShare: 0,
repairShare: 1000,
treasuryShare: 500
});
which is wrong,
https://github.com/Cyfrin/2025-02-raac/blob/main/contracts/core/collectors/FeeCollector.sol#L380-L393
Correct value will be
feeTypes[6] = FeeType({
veRAACShare: 50,
burnShare: 50,
repairShare: 100,
treasuryShare: 0
});
feeTypes[7] = FeeType({
veRAACShare: 50,
burnShare: 0,
repairShare: 100,
treasuryShare: 50
});
Impact
incorrect calculation, as parameters are wrong.
Tools Used
manual review
Recommendations