Skip to content

Commit

Permalink
feat: Adding slitherin detectors (AztecProtocol#4246)
Browse files Browse the repository at this point in the history
Adding slitherin 🐍 detectors
  • Loading branch information
LHerskind authored Jan 31, 2024
1 parent f4127a3 commit f08a063
Show file tree
Hide file tree
Showing 3 changed files with 168 additions and 34 deletions.
2 changes: 1 addition & 1 deletion l1-contracts/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Building requires foundry.
FROM ghcr.io/foundry-rs/foundry:nightly-4a643801d0b3855934cdec778e33e79c79971783
RUN apk update && apk add git jq bash nodejs npm yarn python3 py3-pip && pip3 install slither-analyzer
RUN apk update && apk add git jq bash nodejs npm yarn python3 py3-pip && pip3 install slither-analyzer slitherin
WORKDIR /usr/src/l1-contracts
COPY . .
RUN git init
Expand Down
4 changes: 2 additions & 2 deletions l1-contracts/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ yarn lint

---

# Slither
# Slither & Slitherin

We use slither as an automatic way to find blunders and common vulnerabilities in our contracts. It is not part of the docker image due to its slowness, but it can be run using the following command to generate a markdown file with the results:
```bash
Expand All @@ -85,6 +85,6 @@ yarn slither

When this command is run in CI, it will fail if the markdown file generated in docker don't match the one in the repository.

We assume that you already have slither installed. You can install it with `pip3 install slither-analyzer`. It is kept out of the bootstrap script as it is not a requirement for people who just want to run tests or are uninterested in the contracts.
We assume that you already have slither installed. You can install it with `pip3 install slither-analyzer slitherin`. It is kept out of the bootstrap script as it is not a requirement for people who just want to run tests or are uninterested in the contracts.

> We are not running the `naming-convention` detector because we have our own rules for naming which is enforced by the linter.
Loading

0 comments on commit f08a063

Please sign in to comment.