Toly’s live-market bounty: “Break the live market and keep the insurance fund… If you pull it out on-chain, it’s yours.” The 70 USDC insurance pot on the seeded SOL/USD market was claimed on-chain on 2026-11-25 via an insurance-shares type confusion the Lean proofs structurally cannot see. This page is the full record: root cause, the exact claim transactions, and the fix.
handleCloseAccount (Program.lean:1403–1433) zeroes the 4-byte magic and drains lamports. Every other byte of the account survives.
shareshandleDepositInsurance (Program.lean:679–699): when magic == 0 it writes magic, marketId, owner, market — but not shares (offset 80) — then adds the minted amount to whatever bytes are already there.
Layout.lean: a portfolio’s owner spans bytes 56..88, so byte 80 = owner[24:32] — exactly where InsReceipt.shares lives. As a little-endian u64 that is ≈ 263.
So: create a portfolio you own, close it (magic → 0, bytes survive), revive it as an insurance receipt in the same transaction — the leftover owner bytes preload a shares balance of ≈ 8.5e18. WithdrawInsurance then pays out the whole pot. Withdraw is not subject to the 25% maxInsDrawBps draw cap — that bounds only liquidation — so the live market config does nothing to stop it.
Why the proofs miss it: the verified Spec.lean has no byte layer and no account lifecycle. Its init branch silently assumes “magic == 0 ⇒ freshly system-zeroed” — true for system-created accounts, false for an account recycled through the program’s own closeAccount. Program.lean itself carries no theorems, and no refinement lemma links the two.
Every broadcast was gated on a clean simulateTransaction; preflight re-verified the binary hash, market state, and funding. Runtime note: the close dest must be a separate lamport sink — if dest == authority, Solana serializes the duplicate key as an 8-byte stub the Lean AccountView never resolves, and close fails.
| Step | Instructions | Signature |
|---|---|---|
| A | SystemCreateAccount(952) + InitPortfolio (owner = signer) | 2uv9iiQx…hS9Wt |
| TX1 | fund sink → CloseAccount(P, dest = sink) → transfer(signer → P, rent) → DepositInsurance(P, 1) | 4Znsq4z7…9Gfs1 |
| TX2 | WithdrawInsurance(P, burn = totalInsShares = 70000001) | 44B4ucXW…3M9K |
| TX3 | Jupiter swap: full 72.320118 USDC → +1.021735792 SOL | HuRT8MUg…bMGY |
| Item | Value |
|---|---|
| Claimer / signer wallet | J82YD5pPBcBqJThYif1DaCH2vLyU22RbWQDRLtz3v4DB |
| Portfolio reused as forged receipt | 5atDktvTRPJuy92dYMUFXHdPP6kURLCmG2VQHSGV9wQw |
| Signer USDC (after drain) | 2.320118 → 72.320118 |
| Wallet now | 1.050984614 SOL, 0 USDC (full USDC swapped via Jupiter) |
| Market insurance / shares | 70,000,001 → 0 / 0 |
Epilogue: after the drain, the signer swapped the full 72.320118 USDC to +1.021735792 SOL via Jupiter (HuRT8MUg…bMGY). The wallet now holds 1.050984614 SOL and 0 USDC. The bounty market account has since been closed on-chain (first observed closed 2026-11-25 ~20:21 ET, after the claim). The vault token account remains, holding 0 USDC — the live panel above reads both at page load.
| Component | Address |
|---|---|
| Core program | GVV4HCAohuWDTXRHUYLpFECvTUhCUF2qys36vQKtYJsm (sha256 c6dc8329…, = devnet-validated 35cd13c build) |
| DEX | 6nxbqVQREBwW2ESc1sJyPaUH9yZ7MgKE53fQh3Fm1CkH |
| Market (SOL/USD) | 76oGDQbQW3MEteg2uQqf31PyTmFZp8ujZTyGu3kfFSwq |
| Vault (the prize) | 8MqHSrm6v6ccJVQunjnLqfBBWoAhVGrqUV4hdSH9F8i9 |
| Collateral | USDC · EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v |
DepositInsurance init branch must set shares = 0 before addU64At … shares minted. Never add into a field that was never explicitly zeroed.CloseAccount must zero the whole account (data[0..dataLen]), not just the magic, before draining lamports.Defense in depth: require exact receipt size on init, and/or gate the magic == 0 init on a verifiably freshly-created (system-zeroed, correct-length) account; write a CLOSED discriminator on close.
C-1 — discovered by the @percolator bot (Track C audit), independently verified end-to-end (code review + LiteSVM against the mainnet-identical ELF + the live claim). Two further audit tracks (matcher & oracle review) ran in parallel; the full reports, leads LEAD-001…004, and the PoC live in the private repo Solizardking/percolator-bounty.
RefreshLeg force-haircut capture (permissionless haircut of an unsettled winner)RefreshLeg / Trade / ClearDeadLeg / ForceClosePairFill forwards the caller-supplied mode byte unchecked — spread extraction from LP capital