.---. ,--. ,-- ,----. ,--. ,--. ,-. .----. ,------.,------,
/ . | | \ | | | ._. \ | | `\ . '.' /\_.-, || .---'| /`. '
/ /| | | . '| | | |_| | | | \ / |_ <(| '--. | |_.' |
/ '-' ||| |\ | | .-. |(| '_ / /) .-. \ || .--' | . .'
`---| |'| | \ | | | | | | | / /` \ `-' /| `---.| |\ \
`--' `--' `--' `--' `--' `-----' `--' `---'' `------'`--' '--'
yarn analyze <BASE_PATH> <SCOPE_FILE> <GITHUB_URL>
# Example
yarn analyze contracts scope.example.txtBASE_PATHis a relative path to the folder containing the smart contracts.SCOPE_FILEis an optional file containg a specific smart contracts scope (see scope.example.txt)GITHUB_URLis an optional url to generate links to github in the report- The output will be saved in a
report.mdfile.
| Repository | Report |
|---|---|
| Holograph | Report |
| 3xcalibur | Report |
| Inverse Finance | Report |
| Paladin | Report |
| zkSync | Report |
You'll need Node.js and Yarn. Then clone the repo and run:
yarnYou're all set!
In order to be able to run 4naly3er as a command in any folder, like when you clone a new C4 repo for a contest, you will need to:
- install ts-node globally
npm install -g ts-node- install 4naly3er globally
npm install -g .And now your 4naly3er command will be always available in any repository you wish to analyze. Enjoy!
Please copy the .env.example file to .env and fill out the details if you have a ChatGPT API key. You can also set the API key as an environment variable.
cp .env.example .envIf you want to disable ChatGPT while testing other implementations, you can set OPENAI_ENABLED=false.
You're more than welcome to contribute! For help you can check CONTRIBUTING.md