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

ghostpatch (Neural Rays)

MCP Server

ghostpatch

GhostPatch是一款AI驱动的安全漏洞扫描工具,支持本地运行,无需额外基础设施,提供多种编程语言和漏洞检测功能。

工具数

8

提示词数

0

GitHub Stars

2

资源数

0
安全TypeScriptClaude漏洞检测Claude

安装说明

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

作者 / 组织

NeuralRays

提供方

NeuralRays

最后核验

2026/5/17 20:20

运行时

Node.js

快速接入

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

命令预览

npx ghostpatch scan --output sarif -s medium > results.sarif

详细介绍

Ghostpatch

](https://www.npmjs.com/package/ghostpatch) ](https://github.com/NeuralRays/ghostpatch/releases) ![License: MIT](https://opensource.org/licenses/MIT) ](https://nodejs.org) ![TypeScript](https://www.typescriptlang.org) ![Tests](https://github.com/NeuralRays/ghostpatch) ![OWASP Top 10](https://owasp.org/www-project-top-ten/) ![Security Rules](https://github.com/NeuralRays/ghostpatch) ![Languages](https://github.com/NeuralRays/ghostpatch) ![MCP](https://github.com/NeuralRays/ghostpatch) ![AI Powered](https://github.com/NeuralRays/ghostpatch)

AI驱动的安全漏洞扫描程序 它通过npm在本地运行,无需任何基础设施设置。

用途 拥抱默认情况下无脸模特 (零成本),可选 安thropic克劳德OpenAI GPT 以便进行更深入的分析。包括用于AI编码代理集成的CLI、库API和MCP服务器。

特性

  • 200+安全规则 涵盖OWASP Top 10、CWE等
  • 15种语言:TypeScript、JavaScript、Python、Java、Go、Rust、C、C++、C#、PHP、Ruby、Swift、Kotlin、Shell、SQL
  • 10个专用探测器:注入、身份验证、加密、机密、SSRF、路径遍历、原型污染、反序列化、依赖、配置错误
  • 人工智能驱动的零日检测 使用HuggingFace(免费)、Anthropic或OpenAI
  • 4种输出格式:终端(彩色)、JSON、SARIF(GitHub/VS代码)、HTML报告
  • MCP服务器 配备8个AI编码代理集成工具
  • 观看模式 用于开发过程中的连续扫描
  • 零配置 --开箱即用,可通过配置 .ghostpatch.json

快速开始

# Install globally
npm install -g ghostpatch

# Scan current directory
ghostpatch scan

# Scan specific path
ghostpatch scan ./src

# Short alias
gp scan

# Scan for secrets only
ghostpatch secrets

# Check dependencies
ghostpatch deps

# Generate HTML report
ghostpatch report

# Enable AI analysis
ghostpatch scan --ai
ghostpatch scan --ai --provider anthropic

CLI命令

ghostpatch scan [path]           # Full security scan
  -o, --output           # json | sarif | html | terminal (default: terminal)
  -s, --severity          # critical | high | medium | low | info
  --ai                           # Enable AI-enhanced analysis
  --provider               # huggingface | anthropic | openai
  --fix                          # Show fix suggestions
  -q, --quiet                    # Minimal output

ghostpatch secrets [path]        # Scan for hardcoded secrets only
ghostpatch deps [path]           # Dependency vulnerability check
ghostpatch watch [path]          # Watch mode — scan on file changes
ghostpatch report [path]         # Generate HTML report
ghostpatch serve                 # Start MCP server (stdio)
ghostpatch install               # Configure MCP for Claude Code

AI提供商

提供商成本设置型号
拥抱脸 (默认)免费可选 HF_TOKEN env varQwen2.5编码-32B
Anthropic已付ANTHROPIC_API_KEY 环境变量克劳德十四行诗4.5
开放人工智能已付OPENAI_API_KEY 环境变量GPT-4o
# Use free HuggingFace (default)
ghostpatch scan --ai

# Use Anthropic Claude
export ANTHROPIC_API_KEY=sk-ant-...
ghostpatch scan --ai --provider anthropic

# Use OpenAI
export OPENAI_API_KEY=sk-...
ghostpatch scan --ai --provider openai

库API

import { scan, generateReport, Severity } from 'ghostpatch';

// Full scan
const result = await scan('./my-project', {
  severity: Severity.MEDIUM,
  ai: true,
  provider: 'huggingface',
});

// Generate report
const html = generateReport(result, 'html');
const json = generateReport(result, 'json');
const sarif = generateReport(result, 'sarif');

// Access findings
console.log(`Found ${result.summary.total} issues`);
for (const finding of result.findings) {
  console.log(`${finding.severity}: ${finding.title} at ${finding.filePath}:${finding.line}`);
}

MCP服务器(AI编码代理集成)

GhostPatch包括一个带有8个工具的MCP服务器,用于与Claude Code等AI编码代理无缝集成。

# Auto-configure for Claude Code
ghostpatch install

# Or manually start
ghostpatch serve

MCP工具

工具说明
ghostpatch_scan项目的全面安全扫描
ghostpatch_scan_file扫描单个文件
ghostpatch_findings使用过滤器获取结果
ghostpatch_finding具体发现的详细信息
ghostpatch_secrets扫描硬编码的秘密
ghostpatch_dependencies检查CVE的依赖关系
ghostpatch_ai_analyze人工智能驱动的深度分析
ghostpatch_status扫描仪状态和统计信息

配置

创建 .ghostpatch.json 在项目根目录中:

{
  "exclude": ["node_modules/**", "dist/**", "*.min.js"],
  "severity": "medium",
  "ai": {
    "provider": "huggingface",
    "model": "auto"
  },
  "rules": {
    "disabled": ["LOG003"],
    "custom": []
  },
  "maxFileSize": 1048576,
  "languages": "auto"
}

安全类别

OWASP类别规则
A01访问控制中断BAC001–BAC010
A02加密失败CRYPT001–CRYPT012,SEC001–SEC014
A03注射INJ001–INJ018,PROT001–PROT002
A04不安全设计DES001–DES007
A05安全配置错误CFG001-CFG010
A06易损部件DEP001-DEP003
A07身份验证失败AUTH001–AUTH008
A08数据完整性故障SER001–SER004
A09日志记录失败LOG001–LOG003

.A10.SSRF.SSRF001–SSRF002。

输出格式

终端

带有严重性图标、代码片段和修复建议的彩色输出。

JSON

用于CI/CD集成的机器可读结构化输出。

萨里夫

静态分析结果交换格式——与GitHub代码扫描和VS代码兼容。

超文本标记语言

具有严重性图表、查找细节和补救建议的专业独立报告。

CI/CD集成

# GitHub Actions
- name: Security Scan
  run: |
    npx ghostpatch scan --output sarif -s medium > results.sarif

- name: Upload SARIF
  uses: github/codeql-action/upload-sarif@v3
  with:
    sarif_file: results.sarif

贡献

我们欢迎捐款!以下是如何参与其中:

报告问题

发现错误或有功能请求? 打开一个问题 与:

  • 对问题或建议的清晰描述
  • 复制步骤(针对bug)
  • 预期行为与实际行为
  • 您的环境(操作系统,Node.js版本)

提交拉取请求

  1. 分叉 存储库
  2. 创建 特征分支: git checkout -b feature/my-feature
  3. 制造 您的更改和添加测试
  4. 测验: npm test
  5. 构建 验证: npm run build
  6. 提交 您的更改: git commit -m "Add my feature"
  7. 到你的叉子: git push origin feature/my-feature
  8. 打开拉取请求 反对 master

开发设置

git clone https://github.com/NeuralRays/ghostpatch.git
cd ghostpatch
npm install
npm run build
npm test

我们正在寻找什么

  • 新的安全检测规则和模式
  • 支持其他编程语言
  • 改进了人工智能提示工程,以实现更好的分析
  • 错误修复和误报减少
  • 文档改进
  • CI/CD集成示例

行为准则

请在所有互动中保持尊重和建设性。我们致力于为每个人提供热情和包容的体验。

安全

如果您在GhostPatch中发现安全漏洞,请通过电子邮件负责任地报告 neuralsoft@injectedsecurity.pro 而不是公开问题。

创建者和维护者

神经射线 — | neuralsoft@injectedsecurity.pro

许可证

MIT许可证——见 许可证 了解详情。

______________________________________________________________________

GhostPatch — Scan. Detect. Secure.

Built with TypeScript. Powered by AI.

目录标签

目录标签

安全TypeScriptClaude漏洞检测安全扫描本地部署AI驱动编程语言支持CI/CD集成

支持客户端

Claude

接入字段

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

stdio

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

none

运行时(runtime,运行环境)

Node.js

来源包(packageName,安装包名)

ghostpatch

工具数量(toolCount,工具数)

8

资源数量(resourceCount,资源数)

0

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

0

权限和风险

stdionone部署方式未说明

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

安装前确认

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

来源信息

继续浏览同类 MCP