Audit tooling

Pre-audit checklists

Pick a protocol category. You get the root causes that killed similar protocols, the protocols they killed, and the checks that find them.

Oracles & Price Feeds

01

Spot-pool price accepted

The protocol prices assets from a pool it itself manipulates — flash loans move the price and borrow/swap at the manipulated rate.

KilledHundredMoolaFireBird

Checks

  • Every price source: Chainlink feed, TWAP, or live pool read? Live pool read = suspect
02

No freshness / staleness check

latestRoundData is consumed without checking updatedAt — a stale or poisoned price passes.

KilledFrxEthEth dual-oracle classMultiple 2022-23 exploits

Checks

  • grep -rn "latestRoundData" <repo> — are roundId/answeredInRound/updatedAt all validated?
03

Dual-oracle spread not validated

Two feeds are averaged or picked without checking they agree — one manipulated feed drags the price.

KilledAlchemix H-02/H-09 class

Checks

  • Is the spread between feeds bounded before use?
04

L2 sequencer-uptime unchecked

On L2s the sequencer can go down while the feed serves stale prices — prices are accepted as fresh.

KilledL2 oracle class

Checks

  • On L2: is the sequencer-uptime feed checked before consuming prices?
05

Decimals / unit mismatch

A feed with 8 decimals is multiplied as if 18 (or vice versa) — every price is off by 1e10.

KilledDecimal-mishandling incidents across 2021-23

Checks

  • Normalize every feed to 1e18 with an explicit decimals read — never hardcode