# Auction.sol#settleAuction() Bonder may not be able to settle a bonded auction, leading to loss of funds

Auction.settleAuction() reverts when computed newRatio falls below minIbRatio, so a bonder's bond can never settle and gets burned by bondBurn().

- Payout: Audit contest
- Severity: medium
- Program: Kuiper
- Found by: WatchPug
- Disclosed: 2022-05-02
- Write-up quality: 6/10
- Original: https://github.com/code-423n4/2021-12-defiprotocol-findings/issues/106
- Library page: https://bugbountylibrary.com/r/c4%3A2021-12-defiprotocol%3AM-07
- Tags: area:web3 domain:web3 impact:funds-loss kind:contest platform:code4rena sev:medium tech:evm tech:solidity vuln:business-logic

**Target:** Auction.sol settleAuction() / bondForRebalance() in DeFi basket protocol
**Root cause:** settleAuction() recomputes newRatio from bondBlock and requires newRatio >= minIbRatio, but bondForRebalance() never checks this at bond time; if the ratio decays below minIbRatio before settlement, settleAuction() always reverts with no cancel/refund path.
**Steps:**
1. Bonder calls `bondForRebalance()` paying `bondAmount = totalSupply / bondPercentDiv` (e.g. 100 tokens) at some block after auctionStart.
2. Time passes; newRatio = auctionMultiplier*ibRatio - (bondBlock-auctionStart)*BASE/auctionDecrement decays below pendingWeights.minIbRatio.
3. Bonder calls `settleAuction()`; `require(newRatio >= minIbRatio)` reverts every time.
4. No cancel/refund function exists; after a day anyone calls `bondBurn()` and the bonder's bondAmount is burned.
**How found:** Code reading of settleAuction()'s newRatio computation and the require against minIbRatio, noticing bondForRebalance() lacks the same check and there is no refund path.
**Exploitation:** Bonder's locked bond is permanently stuck and then burned via bondBurn() once the ratio decays past minIbRatio; no attacker capital needed, loss is the bond amount.
**Insight:** When a time-decaying value is validated only at settlement, check whether the same predicate should gate the earlier deposit/bond step; otherwise a depositor can lock funds into a state that can never satisfy the settlement require.
