20,000 USDC
View results
Submission Details
Severity: high
Valid

The refinance function allows borrowers to avoid being liquidated

Summary

The refinance function inside Lender.sol does never check if there is an active auction running or the auction even ended already, and the user can be liquidated anytime. But the function resets the auctionStartTimestamp and therefore can be called to avoid being liquidated.

Vulnerability Details

If a borrower does not want to pay back their debt and also keep their collateral, they can as long as there are any offers, call the refinance function every time a lender puts their loan inside an auction, or right before being liquidated.

Impact

The borrower is able to avoid being liquidated.

Tools Used

Manual Review, Foundry, VSCode

Recommendations

Revert inside the refinance function if auctionStartTimestamp is unequal the default value.

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.

Give us feedback!