Skip to main content

What Happened

The investigator’s post-mortem dates the Sonic exploit to March 28, 2025 and describes approximately $700,000 extracted by manipulating the balances used to value Beets LP collateral. Borrowing against the inflated valuation and reversing the manipulation left bad debt. Vicuna investigator post-mortem.

Attack Mechanism

The lending market accepted Beets LP tokens as collateral and valued them from pool balances. A large swap distorted the composition used by that valuation, temporarily raising the reported collateral value. The attacker borrowed against it and then reversed the manipulation, leaving debt backed by a lower-value position. A naive sum of reserves multiplied by component prices is sensitive to the reserve mix at the observation point. A useful valuation policy must account for the pool’s invariant, share supply, fees, and independently priced components. It must also measure the price consumed by borrowing, not just the value after the attacker restores the pool. Configure the example’s reader/calldata to obtain the LP collateral price and select the lending market’s borrow(uint256) entry point. The pre-call snapshot then observes the valuation presented to that borrow. The post-call check also catches a lasting change during the operation. A 500-bps limit is an illustrative bound on movement from the transaction-start valuation.

Assertion Example

What This Check Covers

A deviation limit is not a fair-LP-pricing formula. Manipulation established before the transaction, alternate borrowing paths, or an unsafe price calculated only inside the call need additional coverage. Stable, weighted and constant-product pools require different valuation models.