This project provides:
- A security focused Solidity environment for analyzing the Ampleforth protocol and ecosystem
- A database of Ampleforth contracts onchain configurations
- Security reviews and incident reports created by
ample-frens
To install as foundry module:
$ forge install ample-frens/labTo install as git repository:
$ git clone https://github.com/ample-frens/labSet the RPC_URL variable inside .env to an Ethereum rpc node and source .env:
$ source .envThe chaincheck test suite verifies the current Ethereum mainnet state against the lab's local
database db/. This ensures changes in security configurations are noticed.
Run via:
$ forge test --mc "Chaincheck"The healthcheck test suite consists of multiple healthchecks against different parts of the
protocol(s) that are run against the current Ethereum mainnet state.
Run via:
$ forge test --mc "Healthcheck"- The monetary policy executed a rebase in the last 24 hours
- The CPI oracle provides valid data
Every CPI oracle provider provides a valid report- The market oracle provides valid data
Every market oracle provider provides a valid report- Every transaction stored in the orchestrator is enabled
- Every orchestrator transaction is executable
- The ForthDAO timelock owns every protocol contract
- A DAO vote can be initiated and executed before a CPI report's activation delay passed
- SPOT holds no raw AMPL
- Bond issuer has at least three active bonds
The invariants test suite verifies different invariants against the current Ethereum mainnet
state.
Run via:
$ forge test --mc "Invariants"- SPOT's underlying is AMPL
- SPOT's
_reserveAt(0)is AMPL - Deposit bond is collateralized via AMPL
- Deposit tranche is senior
- Every issued bond is collateralized via AMPL