NeuroForgeAI-dev/smart-contract-auditor

GitHub: NeuroForgeAI-dev/smart-contract-auditor

一款基于Python的自动化智能合约漏洞扫描工具,支持多链合约审计和15+种常见安全漏洞检测。

Stars: 0 | Forks: 0

# 🔍 智能合约审计器

## 🚀 功能特性 - **15+ 检测器**:Reentrancy、整数溢出、未检查调用、抢跑交易 等。 - **多链支持**:Ethereum、BSC、Polygon、Arbitrum、Solana - **CLI & API**:命令行工具 + REST API - **报告生成**:JSON 和 Markdown 漏洞报告 - **Etherscan 集成**:通过地址获取并审计已验证的合约 - **严重性分类**:Critical(严重)、High(高危)、Medium(中危)、Low(低危)、Informational(提示) ## ⚡ 快速开始 ``` pip install -r requirements.txt # 审计本地 contract python auditor.py --file contracts/vulnerable.sol # 按地址审计(需要 Etherscan API key) python auditor.py --address 0x1234...abcd --chain ethereum # 生成 markdown 报告 python auditor.py --file contracts/token.sol --format markdown -o report.md ``` ## 🔎 支持的检测器 | # | 检测器 | 严重性 | 描述 | |---|----------|----------|-------------| | 1 | Reentrancy | Critical | 外部调用后的状态更改 | | 2 | Integer Overflow | High | 未检查的算术运算 | | 3 | Unchecked Return | High | 忽略调用的返回值 | | 4 | Access Control | Critical | 缺失或弱访问修饰符 | | 5 | Front-Running | Medium | 交易顺序依赖性 | | 6 | Timestamp Dependence | Low | Block.timestamp 操纵 | | 7 | Delegatecall Injection | Critical | 不安全的 delegatecall 使用 | | 8 | Self-Destruct | High | 未受保护的 selfdestruct | | 9 | Gas Limit DoS | Medium | 无界循环 | | 10 | Flash Loan Attack | High | 价格预言机操纵 | ## 📊 示例报告 ``` { "contract": "VulnerableToken.sol", "findings": 3, "critical": 1, "high": 1, "medium": 1, "details": [ { "detector": "reentrancy", "severity": "CRITICAL", "line": 42, "description": "State variable 'balance' modified after external call" } ] } ``` ## 📄 许可证 MIT — 查看 [LICENSE](LICENSE) 由 [NeuroForge AI](https://github.com/NeuroForgeAI-dev) 构建
标签:CISA项目, CVE, DeFi安全, DNS 反向解析, Ethereum, Etherscan, Flash Loan Attack, Front-Running, Hardhat, Python, REST API, Solidity, Streamlit, Web3安全, 云安全监控, 加密, 区块链安全, 多链支持, 密码管理, 对称加密, 数字签名, 整数溢出, 文档结构分析, 无后门, 智能合约审计, 漏洞扫描器, 自动化审计, 访问控制, 逆向工具, 配置错误, 重入攻击检测, 静态分析