Skip to main content
Glama
mcp-contract-security

mcp-contract-security

by mastrophot

mcp-contract-security

用于智能合约安全扫描的 MCP 服务器。

实现了所需的工具:

  • scan_contract

  • compare_security_models

  • audit_checklist

支持的语言:

  • solidity

  • rust

  • typescript

检查内容

scan_contract 目前可检测以下启发式模式:

  • 重入攻击

  • 整数溢出/下溢风险

  • 访问控制问题

  • 抢跑交易暴露

  • 预言机操纵风险

输出包括:

  • 带有严重级别/类型/行号的漏洞列表

  • security_score

  • near_equivalent_score

  • 针对 NEAR 的安全说明和建议

Related MCP server: meok-mcp-injection-scan-mcp

安装

npm install -g mcp-contract-security

已发布的包:

MCP 配置(Claude Desktop)

{
  "mcpServers": {
    "contract-security": {
      "command": "mcp-contract-security"
    }
  }
}

工具用法

scan_contract

输入:

{
  "code": "contract source code here",
  "language": "solidity"
}

compare_security_models

输入(可选):

{
  "language": "solidity"
}

audit_checklist

输入(可选):

{
  "language": "rust"
}

本地开发

npm install
npm run check

交付资产

其他发布资产已准备在 deliverables/ 目录中:

  • deliverables/mcp-registry-submission.md

  • deliverables/security-subreddit-posts.md

  • deliverables/blog-why-near-contracts-safer.md

  • server.json(MCP Registry 元数据,已通过 schema 验证)

许可证

MIT

Available Tools

3 tools
audit_checklistB

Return a practical smart contract security checklist with NEAR-specific items.

Inputs: language.

compare_security_modelsB

Compare NEAR vs Ethereum security architecture and risk profile.

Inputs: language.

scan_contractB

Scan contract code for common vulnerabilities and include NEAR-specific security notes.

Inputs: code (required), language (required).

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.7/5.0

    Scored across 3 tools

    Disambiguation5/5

    Each tool has a clearly distinct purpose: scanning contracts for vulnerabilities, comparing architectures, and providing checklists. There is no meaningful overlap that would cause an agent to select the wrong tool.

    Naming Consistency4/5

    Two tools follow a verb_noun pattern (scan_contract, compare_security_models), while audit_checklist is more of a noun phrase. The pattern is mostly predictable and readable, with only a minor deviation.

    Tool Count4/5

    Three tools is a reasonable scope for a focused contract security server. It is slightly small but each tool serves a distinct, justified function within the domain.

    Completeness4/5

    The toolset covers scanning, comparative analysis, and actionable guidance, which gives agents a solid workflow. It lacks deeper features like detailed report generation or code fixes, but the core security assessment use case is well covered.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers