
Contract Security Scanner
io.github.mastrophot由 GitHub 账号 mastrophot 发布v0.1.1更新于 Oct 24, 2026
MCP smart contract scanner with NEAR-focused security context.
概览
一个本地 MCP 服务器,扫描智能合约源码中的常见安全弱点,并返回带评分和 NEAR 相关说明的报告。
- 可以做什么
- 扫描 Solidity、Rust 或 TypeScript 合约源码,检测重入、整数溢出、访问控制问题、抢跑和预言机操纵等启发式模式,返回含严重程度、类型和行号的漏洞列表,以及安全评分、NEAR 等效评分和 NEAR 相关安全说明与建议。比较不同语言的安全模型。为指定语言生成审计清单。
- 适用场景
- 适合在审查或审计智能合约代码时做快速启发式检查、获取审计清单,或在深入人工审计前了解 NEAR 相关的安全背景。
- 运行要求
- 作为本地进程运行,需从 npm 包 mcp-contract-security 安装(需要 Node.js)。未声明认证、环境变量或请求头。仅支持桌面客户端。
安装
在 SourceWeft 中
- 打开 控制台中的 Contract Security Scanner,将其添加到工作区。
- 为需要使用其工具的对话启用该服务。
Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。
其他 MCP 客户端
参照 仓库 中的启动说明。
README
mcp-contract-security
MCP server for smart contract security scanning.
Implements the required tools:
scan_contractcompare_security_modelsaudit_checklist
Supports languages:
solidityrusttypescript
What it checks
scan_contract currently detects heuristic patterns for:
- Reentrancy
- Integer overflow/underflow risk
- Access control issues
- Front-running exposure
- Oracle manipulation risk
The output includes:
- vulnerability list with severity/type/line
security_scorenear_equivalent_score- NEAR-specific security notes and recommendation
Install
Published package:
- npm: https://www.npmjs.com/package/mcp-contract-security
- MCP Registry: https://registry.modelcontextprotocol.io/v0/servers/io.github.mastrophot%2Fcontract-security-scanner/versions/0.1.1
MCP config (Claude Desktop)
Tool usage
scan_contract
Input:
compare_security_models
Input (optional):
audit_checklist
Input (optional):
Local development
Deliverable assets
Additional publish assets are prepared in deliverables/:
deliverables/mcp-registry-submission.mddeliverables/security-subreddit-posts.mddeliverables/blog-why-near-contracts-safer.mdserver.json(MCP Registry metadata, schema-validated)
License
MIT
来源:README.md,提交 9f32ff1
工具
0版本历史
1- v0.1.1最新Sep 16, 2026
评分
已满足适用检查项的 50%
该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。
- 近 30 天内可连通25 分
请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。
- 已声明认证方式10 分
请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。
- 已列出工具15 分
请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。
- 描述必需15 分
- 图标10 分
- 文档15 分
- 许可证10 分