During a loan transfer, the original lender is charged with paying the protocol interest and doesn't get this amount back.
This function is called by lenders, to transfer their loan to another pool. In the line:
IERC20(loan.loanToken).transfer(feeReceiver, protocolInterest);
The original lender covers the protocolInterest, but it's based on the borrower's accumulated interest. The lender needs to be reimbursed this amount.
Original lenders could be unfairly charged, leading to monetary loss.
A thorough review of the code base was conducted to identify this issue.
Consider adding the protocolInterest amount to the lender's balance.
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.