
Agent Security Scanner Mcp
io.github.sinewaveai由 GitHub 账号 sinewaveai 发布v2.0.1更新于 Oct 24, 2026
Security layer for AI agents: blocks prompt injection, detects fake packages, scans vulnerabilities.
概览
本地安全扫描器,用于检查 AI 编写的代码、提示词、MCP 服务器和推荐依赖包中的漏洞与注入风险。
- 可以做什么
- 对项目、代码差异、单个文件、提示词或 MCP 服务器执行基于规则的扫描,并给出带 A-F 评级的发现结果。工具族涵盖代码与仓库安全、MCP 与技能审计、提示词与操作安全、依赖包幻觉检测、SBOM 生成与漏洞检查,以及合规证据。可选的语义审查代理会调用 LLM 提供商查找上下文相关问题。
- 适用场景
- 在信任 AI 代理生成或推荐的代码、依赖、提示词或 MCP 工具之前使用,也适合在提交拉取请求或添加新 MCP 服务器之前运行。它是对 npm audit 等工具的补充,而非替代。
- 运行要求
- 以 npm 包形式通过 stdio 在本地运行,需要 Node.js 和 npx。未声明任何账户、API 密钥或环境变量。可选的语义审查代理需要你选择的 LLM 提供商(例如某个 CLI 或 OpenAI),并会把代码发送给该提供商。
安装
在 SourceWeft 中
- 打开 控制台中的 Agent Security Scanner Mcp,将其添加到工作区。
- 为需要使用其工具的对话启用该服务。
Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。
其他 MCP 客户端
参照 仓库 中的启动说明。
README
agent-security-scanner-mcp
Security scanner for AI coding agents, MCP servers, prompts, and AI-suggested packages.
Run it before Claude Code, Cursor, Windsurf, Cline, OpenCode, or another agent trusts new code, tools, prompts, or dependencies.
Copy-Paste Start
Scan any repo and get an A-F agent security grade:
Install the scanner into your AI coding client:
Replace claude-code with cursor, claude-desktop, windsurf, cline, kilo-code, opencode, or cody.
Audit an MCP server before adding it to an agent:
Check AI-generated imports for package hallucinations:
What It Catches
Screenshots
Project Scan
MCP Server Audit
Package Hallucination Detection
Demos
Run a safe local demo that creates intentionally vulnerable fixtures, scans them, and cleans them up.
Expected demo shape:
Install In Your Agent
Then restart the client. Your agent can call the scanner as an MCP tool.
Agent Playbook
Paste this into an agent task when you want it to work safely:
Common Workflows
Before You Trust An Agent-Written PR
Before Installing An MCP Server
Before Adding A Dependency Suggested By AI
Add CI
Generate Share Copy From A Real Scan
CLI Reference
All scanner outputs support context-friendly verbosity:
MCP Tools For Agents
When installed as an MCP server, agents get these tool families:
Why Developers Install It
- One
npxcommand gives an A-F security grade for AI-written code. - MCP-specific checks catch risks that normal SAST tools miss.
- Package hallucination detection checks 4.3M+ package names across npm, PyPI, RubyGems, crates.io, pub.dev, CPAN, and raku.land.
- Output is compact by default so coding agents can read it without burning the context window.
- Works as a CLI, MCP server, GitHub Action workflow, Apify Actor, and semantic review agent.
- MIT licensed.
Semantic Code Review
cr-agent is bundled with the npm package for LLM-powered semantic review. It reads project intent, then looks for code that violates that intent.
Use it when rule-based scanning is not enough and the question is, "Does this code make sense for what this project is supposed to do?"
SBOM And Compliance Evidence
Useful before releases, SOC 2 evidence collection, vendor reviews, and AI-generated dependency changes.
Apify Actor
Run the scanner as an Apify Actor when you want a hosted API or scheduled scans:
Latest Release
v4.5.8 adds diff-scoped cr-agent semantic review, fixes nested repository diff lookups, and filters semantic findings to changed hunks so PR reviews stay focused on code that actually changed.
Detailed release history lives in CHANGELOG.md. The older README-embedded changelog is archived at archive/README_CHANGELOG_ARCHIVE.md.
FAQ
Is this only for MCP servers? No. It scans normal repos, diffs, prompts, actions, packages, SBOMs, MCP servers, and AI skills.
Does it send my source code anywhere?
Rule-based CLI and MCP scans are local. cr-agent uses the provider you choose for semantic review.
Is it a replacement for npm audit? No. It complements npm audit by catching AI-specific risks: hallucinated packages, prompt injection, MCP tool poisoning, unsafe agent actions, and vulnerable generated code.
What should I run first?
Run npx agent-security-scanner-mcp scan-project . --verbosity compact.
Links
License
MIT
来源:README.md,提交 ef3f20e
工具
0版本历史
1- v2.0.1最新Sep 16, 2026
评分
已满足适用检查项的 50%
该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。
- 近 30 天内可连通25 分
请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。
- 已声明认证方式10 分
请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。
- 已列出工具15 分
请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。
- 描述必需15 分
- 图标10 分
- 文档15 分
- 许可证10 分