A malicious lender can frontrun the borrow call to set the interest rate high.
borrow
function takes only poolId
, debt
, and collateral
as arguments. It does not receive any information about the user's intended interest rate just uses the pool's interest rate. The interest rate of the pool can be freely changed via setPool
. Therefore, a malicious lender can front-run the user's borrow transaction to borrow at the maximum rate.
A malicious lender can make borrowing at a rate user didn't intend.
VS Code
As an argument to the borrow
function, it should receive information about the user's intended interest rate and compare it to the current pool's interest rate.
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.