ChainAudit
Smart contract security scanner — Solidity, Solana/Rust, and L2/Arbitrum/Optimism support.
Install
Mac / Linux / Ubuntu
pip install chainaudit
pip install slither-analyzer
pip install solc-select
solc-select install 0.8.24
solc-select use 0.8.24
# Optional — for Solana/Rust scanning
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
cargo install cargo-audit
Windows
Requires Python 3.12. Download from python.org — check "Add Python to PATH" during install. Python 3.13 not yet supported on Windows.
pip install chainaudit
pip install slither-analyzer
pip install solc-select
solc-select install 0.8.24
solc-select use 0.8.24
If on a college/office network, use mobile hotspot for installation.
Usage
chainaudit scan contract.sol # Solidity file
chainaudit scan program.rs # Solana/Rust program
chainaudit scan ./contracts --recursive # directory
chainaudit scan contracts.zip # zip archive
chainaudit scan contract.sol --json # JSON output
chainaudit scan contract.sol --ml-only # retained; no longer changes behaviour
chainaudit --version # show version
Exit code 1 if CRITICAL vulnerabilities found — blocks deployments in CI.
GitHub Action
- uses: aizen299/smart-contract-auditor@v1
with:
target: contracts/
fail-on-critical: true
What It Detects
EVM (Ethereum, Polygon, BNB Chain...)
| Severity | Examples |
|---|---|
| CRITICAL | Reentrancy, Controlled Delegatecall |
| HIGH | Unchecked Token Transfer, Weak Randomness, tx.origin Auth |
| MEDIUM | Timestamp Dependence, Unchecked Send |
| LOW | Missing Zero Check, Missing Events |
L2 / Arbitrum / Optimism — auto-detected
| Severity | Examples |
|---|---|
| CRITICAL | Cross-Chain Replay Attack, Bridge Reentrancy |
| HIGH | L2 Block Number Assumption, Sequencer Dependence, Address Aliasing |
| MEDIUM | Force-Include Griefing, Gas Price Assumption |
Solana / Rust
| Severity | Examples |
|---|---|
| CRITICAL | Missing Signer Check, Arbitrary CPI, Missing Owner Check |
| HIGH | Integer Overflow, Unsafe Rust Code, CPI Reentrancy, Insecure Randomness |
| MEDIUM | Missing Rent Exemption, PDA Seeds Not Validated |
| LOW | Missing Freeze Authority, Deprecated Anchor Patterns |
Detected via cargo-audit (CVE scanning) + pattern scanning on .rs source files.
ML Predictions
Each finding includes an ML-predicted exploitability score (SmartBugs dataset, 88% accuracy on a held-out split of 143 curated contracts — a triage aid for ranking findings, not a guarantee on arbitrary production code).
{
"title": "Reentrancy",
"severity": "CRITICAL",
"ml_exploitability": "CRITICAL",
"ml_confidence": 0.96,
"chain": "arbitrum"
}
Links
- GitHub: aizen299/smart-contract-auditor
- Web app: chainaudit.vercel.app
- Issues: GitHub Issues
Metadata
Release files for chainaudit 1.2.7
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| chainaudit-1.2.7.tar.gz | 634.8 kB | Without provenance | Details for chainaudit-1.2.7.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| chainaudit-1.2.7-py3-none-any.whl | Python 3 | none | any | Details for chainaudit-1.2.7-py3-none-any.whl |
Total release size: 1.3 MB
Release files / chainaudit-1.2.7.tar.gz
| Download URL | chainaudit-1.2.7.tar.gz |
|---|---|
| Size | 634.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
bacf98ded6c375bb96bb1b4819fe3f594cf522b75f8d3b3c32a68c5e0e5d180e
|
|
BLAKE2b-256 checksum How to use checksums |
93aff87f49dfc652006e5fb6bd4f82a4aee55f575a6c62ce8f8f5f5fc79a4819
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.16
|
Release files / chainaudit-1.2.7-py3-none-any.whl
| Download URL | chainaudit-1.2.7-py3-none-any.whl |
|---|---|
| Size | 643.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f80d0da8d439b132f60ce2b5f5848c7fc47bb71454ef6c91438dc17bb35782b3
|
|
BLAKE2b-256 checksum How to use checksums |
5029c9c1fa65442d3021fa0ef8bf7b19b8f15af97fb280e32879f74f93a5c70f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.11.16
|
Security for chainaudit 1.2.7
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.