Table of Contents
Be sure you have foundry installed (if not, follow instructions here), then run:
yarn install
foundryup
forge install
rm cache -r -fo;rm artifacts -r -fo;rm typechain-types -r -fo; npx hardhat compile
forge build
npx hardhat test
forge test
More details about fuzzing campaign can be found at the Fuzzing Report.
📢
// constructor(string memory name, string memory symbol) ERC20(name, symbol) {}
and comment out in MockERC20:
constructor(string memory name, string memory symbol) ERC20(name, symbol) Ownable(msg.sender) {}
This is necessary due to hardhat/foundry incompatibility issues. 📢
To spin up Echidna in Docker, run:
sudo docker pull trailofbits/eth-security-toolbox
docker run -it --rm -v $PWD:/src trailofbits/eth-security-toolbox
To fuzz test
echidna --contract <CONTRACT-NAME> --config /src/echidna-config.yaml /src/contracts/echidna/<CONTRACT-NAME>.sol
# echidna --contract EchidnaTestDistribution --config echidna-config.yaml contracts/echidna/EchidnaTestDistribution.sol
- contracts developed by luckydegen (Angel Squad)
- fuzzing brought by 0xharold (MAMA AI)