In the LendingPool contract the _rebalanceLiquidity function is meant to either add or remove liquidity to mantain a buffer. It's currently only being called during deposit, borrow and withdraw, but other functions that have transfers are lacking this call.
The repay and finalizeLiquidation functions both have safeTransferFrom functions to receive reserve asset tokens for the repayment of debt, but they lack a call to__ _rebalanceLiquidity, this means that in the case of excess funds from those token inflows the protocol will be missing out on curve yield until deposit, borrow or withdraw are called and _rebalanceLiquidity is executed again.
Loss of yield.
Manual review.
Add a _rebalanceLiquidity call at the end of both the _repay and finalizeLiquidation functions.
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.