Token导航 LogoToken导航TokenDH.com
agentwise (Brandonwise) logo
安全风控未说明官方级别未说明来源级核验

agentwise (Brandonwise)

MCP Server

agentwise是一款快速、离线的AI代理配置安全扫描工具,用于检测MCP服务器和AI代理配置中的安全漏洞和错误配置。

工具数

0

提示词数

0

GitHub Stars

2

资源数

0
安全RustClaude漏洞检测ClaudeCursor

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

作者 / 组织

brandonwise

提供方

brandonwise

最后核验

2026/5/17 20:23

快速接入

先看主来源和安装命令,再打开仓库或文档;下面只保留这个条目的关键接入事实。

详细介绍

agentwise

The fast, offline security scanner for AI agent configurations.

______________________________________________________________________

思考 npm audit,但适用于MCP服务器和AI代理。

$ agentwise scan .

  ╔══════════════════════════════════════════════════════════════╗
  ║  agentwise v0.1.0                                          ║
  ║  MCP Security Scanner                                      ║
  ╚══════════════════════════════════════════════════════════════╝

  ● Scanned 3 configs (12 servers) in 4ms

  ┌──────────────────────────────────────────────────────────────┐
  │  ■ 3 critical  ■ 5 high  ■ 7 medium  ■ 0 low               │
  └──────────────────────────────────────────────────────────────┘

  ✖ CRITICAL  .mcp.json → filesystem  AW-002
    Filesystem server with dangerous root access
    Fix: Add "allowedDirectories" to restrict to project directories

  ✖ CRITICAL  .mcp.json → quickbooks  AW-001
    No authentication on remote MCP server
    Fix: Add authentication via env vars (AUTH_TOKEN, API_KEY, etc.)

  ▲ HIGH      .mcp.json → filesystem  AW-006
    CVE-2025-53110: Path traversal in server-filesystem =0.6.3

  ╔══════════════════════════════════════════════════════════════╗
  ║  Score: 12/100  ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░  Grade: F   ║
  ╚══════════════════════════════════════════════════════════════╝

运作原理

为什么是代理?

在过去60天内,针对MCP服务器的CVE超过30个。36%的MCP服务器提供零身份验证。您的AI代理设置可能存在漏洞。

每个现有的扫描器都是Python、JavaScript或TypeScript。他们需要 pip installnpm install,提取了数十个依赖项,并且有些依赖项需要每次扫描都要花钱的LLM API调用。

||agentwise|Snyk代理扫描|Cisco mcp扫描器|mcp屏蔽| |--|-----------|-----------------|---------------------|------------| |语言| Rust | Python | Python | TypeScript| |安装|单二进制|pip/uvx|pip|npm| |速度等级|毫秒|秒|秒|| |离线|是|否|否|是| |EPSS评分|是|否|否|无| |供应链|是|否|否|不| |deps.dev |是|否|否|不|

性能(测量)

在macOS arm64上测量,发布版本,使用 hyperfine.

代理扫描延迟

命令平均时间
agentwise scan testdata/vulnerable-mcp.json (5台服务器)3.2毫秒
agentwise scan research/configs/ (109台服务器)3.9毫秒

快速头对头(相同的易损夹具)

工具平均运行时间
agentwise3.1毫秒
思科 mcp-scanner (--analyzers yara)2.68秒
mcp-shield (默认运行)60.62秒

笔记:

  • 这些是同一设备上的默认CLI运行(testdata/vulnerable-mcp.json).
  • 一些工具通过设计尝试实时服务器连接,这增加了运行时间。
  • 使用中的基准命令在本地复制 research/benchmarks.md.

真实世界的调查结果快照

从扫描 109个MCP服务器条目 从公开的GitHub配置+官方文档中收集:

  • 共发现130项 (13高,117中)
  • 100% 缺少刀具列表(AW-007)
  • 8.26% 具有不受限制的文件系统访问权限(AW-002)
  • 1.83% 暴露的硬编码秘密(AW-004)
  • 不安全的明文传输和通配符绑定暴露(http://, ws://, 0.0.0.0, [::])仍然出现在公开场合(AW-005)

完整的方法论、来源归因和原始输出都在 research/FINDINGS.mdresearch/scan-results.json.

信任信号

  • 4.0 MB 发布二进制文件
  • 255/255项测试通过
  • 0个简短的警告 随着 -D warnings
  • 0个已知的Rust依赖漏洞 (cargo audit)

安装

来自crates.io(即将推出)

agentwise 尚未在crates.io上发布。

立即安装Cargo

cargo install --git https://github.com/brandonwise/agentwise agentwise

立即从源代码构建

git clone https://github.com/brandonwise/agentwise
cd agentwise
cargo build --release
./target/release/agentwise --version

预构建二进制文件

curl -sSf https://raw.githubusercontent.com/brandonwise/agentwise/main/install.sh | sh

家酿

brew tap brandonwise/tap
brew install agentwise

扫描工作流程

快速开始

# Scan current directory (auto-detects MCP configs)
agentwise scan .

# Scan a specific config file
agentwise scan ~/.mcp.json

# Scan a Codex MCP config
agentwise scan ~/.codex/config.toml

# Live mode: query OSV + EPSS for real-time CVE data
agentwise scan . --live

# Supply chain analysis (npm registry + deps.dev)
agentwise scan . --supply-chain

# Fail CI on high+ severity findings
agentwise scan . --fail-on high

支持的配置

agentwise自动检测和扫描:

  • .mcp.json --Claude Code项目级配置
  • claude_desktop_config.json --克劳德桌面
  • .cursor/mcp.json --光标编辑器
  • ~/.codex/config.toml.codex/config.toml --Codex命令行界面+集成开发环境
  • mcp.json --通用MCP配置
  • 任何JSON文件 mcpServerscontext_servers 作为论据通过
  • 任何法典 config.toml 随着 [mcp_servers.] 作为参数传递的表

威胁覆盖范围

检测规则

12条内置规则,涵盖配置错误、已知CVE和供应链风险:

ID规则严重性
AW-001远程服务器上没有身份验证严重
AW-002过度许可的文件系统访问严重
AW-003无限制的shell/exec访问关键
AW-004明文配置中的秘密
AW-005传输不安全或通配符绑定暴露(http://, ws://, 0.0.0.0, [::])
AW-006已知CVE匹配(嵌入式+OSV)严重/高
AW-007缺少刀具列表中等
AW-008无需选择加入即可编写工具中等
AW-009无限制网络/获取工具中等
AW-010快速注射表面中等
AW-011供应链风险信号高/中
AW-012深度依赖链(deps.dev)高/中

实时模式

--live 标记查询 OSV.dev 用于实时漏洞数据和 第一个EPSS 用于计算开采概率得分。这告诉你 *什么* 易受攻击,但 *有多大可能* 它将在野外被利用。

$ agentwise scan . --live

  ...

  ▲ HIGH      .mcp.json → filesystem  AW-006 [LIVE]
    CVE-2025-53110: Path traversal in server-filesystem =0.6.3

  ● Live CVE check: queried OSV for 8 packages (2 new vulnerabilities found)

  ...

EPSS得分超过50%被标记为在野外被积极利用。这 --offline 标志禁用所有网络查询,仅使用嵌入式数据库。

供应链分析

--supply-chain flag分析每个MCP服务器的npm包以获取供应链风险信号:单个维护包、拼写错误、安装脚本、低下载次数和依赖图深度 deps.dev.

$ agentwise scan . --supply-chain

  ...

  ▲ HIGH      .mcp.json → sketchy-mcp  AW-011 [SUPPLY-CHAIN]
    Supply chain risk: HIGH for sketchy-mcp
    ├ Single maintainer 'anon42' (account takeover risk)
    ├ Has postinstall script
    └ 43 weekly downloads
    Fix: Review package provenance and consider official @modelcontextprotocol packages

  ● MEDIUM    .mcp.json → some-tool  AW-012 [DEPS.DEV]
    Deep dependency chain: 247 transitive deps
    ├ 247 transitive dependencies (high risk)
    └ 2 transitive deps have known advisories
    Fix: Review transitive dependencies and update packages with advisories

  ...

CI/CD集成

GitHub操作

使用捆绑的复合操作进行发布安装、更安全的参数处理和源代码模式自检:

- uses: brandonwise/agentwise@v1
  with:
    path: ./Agent Configs/.mcp.json
    format: sarif
    output: ./reports/agentwise.sarif
    fail-on: high

- uses: github/codeql-action/upload-sarif@v3
  with:
    sarif_file: ./reports/agentwise.sarif

笔记:

  • 支持带空格的路径和输出文件。
  • install-mode: source 构建已签出的操作源,而不是下载版本。可用于测试pull请求中的操作更改。
  • --fail-on 当发现达到或超过所选严重性时,阈值仍然会关闭作业。

如果你更喜欢手动路径,这仍然有效:

- name: Install agentwise
  run: curl -sSf https://raw.githubusercontent.com/brandonwise/agentwise/main/install.sh | sh

- name: Scan MCP configs
  run: agentwise scan . --fail-on high --format sarif > agentwise.sarif

- uses: github/codeql-action/upload-sarif@v3
  with:
    sarif_file: agentwise.sarif

输出格式

agentwise scan .                                        # Colorized terminal output (default)
agentwise scan . --format json                          # JSON for scripting and pipelines
agentwise scan . --format sarif                         # SARIF for GitHub Code Scanning
agentwise scan . --format html --output report.html     # Dark-themed HTML report
agentwise scan . --format markdown                      # Markdown for PRs/Notion/Confluence
agentwise badge --format svg --output badge.svg         # Shields.io-style SVG badge
agentwise inspect .                                      # Per-server risk posture summary
agentwise inspect . --format json                        # Machine-readable inspect output

基线管理

agentwise 支持在到期时抑制发现:

agentwise baseline init
agentwise baseline show
agentwise baseline add --rule AW-007 --server mcp-fetch --reason "trusted tool for now" --expires 2026-12-31
agentwise baseline remove --rule AW-007 --server mcp-fetch
agentwise baseline prune-expired

解析器兼容性

agentwise 解析多个MCP配置形状:

  • mcpServers
  • context_servers (例如Zed)
  • lsp.{mcpServers|context_servers} 嵌套块

检查模式

inspect 在不更改AW-\*分类法的情况下给出每台服务器的姿态视图:

agentwise inspect .
agentwise inspect ~/.mcp.json --format json

检查输出包括运输类型、身份验证/分配列表存在、包裹固定和风险标签,如 remote_no_auth, unrestricted_network,以及 broad_filesystem.

评分

每次扫描都会产生0到100的安全评分:

等级分数含义
A90-100非常好——风险最小
B80-89好——小问题
C70-79公平——一些担忧
D50-69差——重大风险
F0-49危急——需要立即采取行动

评分权重:关键=-20,高=-10,中=-5,低=-2。

CVE数据库

agentwise附带了一个嵌入式数据库,其中包含22个已知的MCP漏洞,这些漏洞是在构建时编译的。值得注意的条目:

  • CVE-2025-6514 --MCP工具配置中的命令注入(CVSS 10.0)
  • CVE-2026-2256 --在中通过Shell工具提示RCE ms-agent (CVSS 10.0)
  • CVE-2025-59536 --通过克劳德代码项目文件(CVSS 9.8)进行RCE
  • CVE-2026-15503 --集装箱逃生 mcp-server-docker (CVSS 9.6)
  • CVE-2026-31024 --SQL注入 mcp-server-postgres (CVSS 9.1)
  • CVE-2025-53110 --路径遍历 server-filesystem
  • CVE-2025-68143 --Git MCP中的路径遍历+参数注入

随时从OSV更新本地缓存:

agentwise update

路线图

  • \[x\] 12条检测规则(AW-001至AW-012)
  • \[x\] 嵌入式CVE数据库(22+个条目)
  • \[x\] 实时OSV+EPSS增强(--live)
  • \[x\] 供应链分析(--supply-chain)
  • \[x\] deps.dev依赖图分析
  • \[x\] 终端、JSON、SARIF输出
  • \[x\] GitHub行动
  • \[x\] 评分系统(0-100,A-F)
  • \[x\] 自动发现(agentwise scan --auto)
  • \[x\] 检查模式(agentwise inspect)
  • \[\]自定义规则DSL(YAML)
  • \[\]交互式TUI
  • \[\]自动修复(agentwise fix)

贡献

贡献.md最简单的贡献方式是添加新的检测规则——每个规则都是 src/rules/.

许可证

MIT许可证(许可证-麻省理工学院).

______________________________________________________________________

建造于 @布兰登明智因为你的人工智能代理应该比 "auth": null.

目录标签

目录标签

安全RustClaude漏洞检测安全扫描本地部署AI代理安全MCP服务器离线工具AI代理

支持客户端

ClaudeCursor

接入字段

传输方式(transport,传输协议)

未说明

鉴权方式(authType,认证方式)

none

工具数量(toolCount,工具数)

0

资源数量(resourceCount,资源数)

0

提示词数量(promptCount,提示词数)

0

权限和风险

未说明none部署方式未说明

接入前请确认传输方式、认证方式和部署位置,并根据实际工具能力限制访问范围。

安装前确认

不要直接授予不必要的文件、网络或账号权限;先核对安装命令和配置内容。

仍需确认:installCommand

来源信息

继续浏览同类 MCP