The emergencyClose()
function calls repay()
to unwind the borrow position, but does not validate that the repayment completed successfully.
If repay()
reverts or fails to fully repay the borrowed assets for any reason, the contract state and borrow would be left in an inconsistent, partially repaid state.
Reproduction Steps:
Call emergencyClose()
during exploit of repay()
repay()
reverts or does not fully repay amounts
Function does not detect repay()
failure
Borrow position remains outstanding
Borrower could retain access to loaned assets after attempted close
Manual Review
Validate repay()
executes fully by checking borrow balances are zeroed. Revert state on any validation failures to avoid partial closures leaving funds exposed.
Impact: Medium Likelihood: Low The keepers can send tokens directly before closing. Will leave for a sponsor's review but likely to invalidate.
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.