the balanceIncreas, is not used in RToken.sol::mint(), to calculated the accrue interest on the user's existing balance before minting new tokens.
RToken::mint() : https://github.com/Cyfrin/2025-02-raac/blob/89ccb062e2b175374d40d824263a4c0b601bcb7f/contracts/core/tokens/RToken.sol#L114
This function mints a new RToken for a user when they deposit crvToken asset into protocol. However, if the user already has RToken, their previous balance needs to be updated for interest before adding the newly minted amount.
this impact users second, third,.. deposit, not adding balanceIncrease, the additional value the user should receive due to interest accrual to amountToMint, cause to loss of accrued interest when a user deposits more funds.
Manual Review
amountToMint = amountToMint + balanceIncrease
The balanceIncrease is the interest that has already accrued on the user's existing scaledBalance since their last interaction. It's not something you mint as new tokens in the _mint function.
The balanceIncrease is the interest that has already accrued on the user's existing scaledBalance since their last interaction. It's not something you mint as new tokens in the _mint function.
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.