# Malicious borrowers will never repay loans with high interest

Lavarage liquidation check ignores accrued interest, so borrowers with high-interest loans can never be liquidated, locking lender funds indefinitely.

- Payout: Contest reward
- Severity: high
- Program: Lavarage
- Credited: DadeKuma
- Disclosed: 2024-05-29
- Write-up quality: 6/10
- Original: https://github.com/code-423n4/2024-04-lavarage-findings/issues/10
- Library page: https://bugbountylibrary.com/r/c4%3A2024-04-lavarage%3AH-03
- Tags: domain:web3 impact:dos impact:funds-loss kind:contest platform:code4rena sev:high tech:solana technique:source-review vuln:business-logic vuln:liquidation

**Target:** Solana lending protocol liquidation processor
**Root cause:** The liquidation check computes LTV from the original borrowed position_size only, not including accrued interest, so a position whose interest pushes true LTV above 90% still passes the check.
**Steps:**
1. Borrow via swap: position_account.amount = position_size - user_pays, recording only principal.
2. Accrue interest over time without repaying.
3. Attempt liquidation: check `position_account.amount * 1000 / position_size > 900` uses principal only, ignoring owed interest.
4. Since principal LTV stays <=90%, liquidation reverts; borrower keeps funds and never repays.
**How found:** Code review of liquidate.rs liquidation check against swap.rs position accounting; noticed interest owed is never added to the LTV computation.
**Exploitation:** Borrower takes a loan, never repays interest; because liquidation can only trigger on principal LTV >90%, the position stays unliquidatable indefinitely while interest accrues, locking lender capital and generating bad debt.
**Insight:** When auditing lending protocols, verify the liquidation/health check uses total debt including accrued interest, not just principal; a principal-only LTV check lets borrowers free-ride indefinitely.
