PatchProof MCP

PatchProof MCP

Enables local npm supply-chain inspection through tools for repository scanning, SBOM generation, dependency audit, and evidence reporting. Uses deterministic mock data and does not query live APIs.

Category
访问服务器

README

PatchProof MCP

CI

PatchProof is a focused Model Context Protocol server for local npm supply-chain inspection. The MVP exposes four tools with deterministic, offline-friendly behavior.

Current Status

The complete public tool set is implemented and covered by focused tests:

  • scan_repository: bounded repository file and byte counting.
  • generate_sbom: deterministic CycloneDX-shaped SBOM generation from package-lock.json.
  • audit_dependencies: dependency extraction with a deterministic mock vulnerability table.
  • generate_evidence_report: an end-to-end JSON/HTML artifact combining SBOM components, matched vulnerabilities, and upgrade recommendations.

Important limitations:

  • Only npm package-lock.json repositories are supported.
  • audit_dependencies does not yet query the live OSV API. Selecting live currently uses the same deterministic mock data.
  • scan_repository intentionally returns bounded repository statistics; vulnerability matching is handled by audit_dependencies.
  • Reachability classification and verification command execution are not yet integrated into evidence reports.
  • The browser demo uses a bundled fixture and does not inspect arbitrary remote repositories.
  • Both the local CLI and Vercel deployment use the official stateless Streamable HTTP transport.

The Vercel demo exposes a stateless Streamable HTTP endpoint at /api/mcp. For safety, every public tool call is locked to the bundled demo fixture; it does not accept arbitrary server filesystem paths. The landing page calls the endpoint directly and lets reviewers run all four tools without installing an MCP client.

Committed, reproducible report artifacts are available at examples/demo-report.json and examples/demo-report.html. GitHub Actions rebuilds them and fails if the committed evidence becomes stale.

Requirements

  • Node.js 20
  • npm 10

Install And Verify

npm ci
npm run typecheck
npm test
npm run build

The focused core-tool test suite creates a temporary npm repository and calls the four implemented tools directly.

Run

Build first, then start the stdio MCP server:

npm run build
npm run start:stdio

Deploy The Live Demo

Import this GitHub repository into Vercel and deploy with the default settings. The deployment provides:

  • / - a static project and tool overview;
  • /api/mcp - the stateless MCP Streamable HTTP endpoint;
  • a bundled npm fixture containing deterministic mock vulnerabilities.

Verify the deployment:

curl -X POST https://YOUR-DEPLOYMENT.vercel.app/api/mcp \
  -H "Content-Type: application/json" \
  -H "Accept: application/json, text/event-stream" \
  -d '{"jsonrpc":"2.0","id":1,"method":"tools/list"}'

Tool Summary

scan_repository

Input:

{
  "repoRoot": "/authorized/repository",
  "includeHidden": false,
  "followSymlinks": false
}

Returns the resolved repository root, files scanned, bytes read, duration, ignored directories, and the current findings array.

generate_sbom

Input:

{
  "repoRoot": "/authorized/repository",
  "format": "cyclonedx"
}

Returns a deterministic CycloneDX 1.5-shaped component list derived from package-lock.json.

audit_dependencies

Input:

{
  "repoRoot": "/authorized/repository",
  "osvMode": "mock",
  "ecosystem": "npm"
}

Returns parsed dependencies and matching entries from the local deterministic mock vulnerability table.

generate_evidence_report

Input:

{
  "repoRoot": "/authorized/repository",
  "format": "both"
}

Runs the implemented SBOM and deterministic dependency audit together. It returns findings and upgrade recommendations as JSON and, for html or both, a self-contained HTML report with summary metrics.

Architecture

src/server       MCP registration and CLI
src/tools        four public MCP tool definitions
src/scanners     bounded repository traversal
src/parsers      npm lockfile parsing
src/sbom         deterministic SBOM assembly
src/osv          deterministic mock dependency audit
src/reporting    end-to-end JSON and HTML evidence assembly
src/security     path, resource, error, and redaction utilities
src/transport    verified stdio and Streamable HTTP transports
tests/unit       infrastructure and focused core-tool tests

Business logic is kept outside the MCP registry so it can be tested directly.

Security Notes

  • Callers must provide or authorize a repository root.
  • Repository traversal is bounded by file, byte, depth, and time limits.
  • Common generated directories such as .git, node_modules, dist, build, and coverage are ignored.
  • The implemented dependency audit is local and deterministic.

This is an MVP, not a completed security product. Do not rely on it as the sole source for vulnerability or secret detection.

CyOps Arena

The repository was scaffolded and iterated with CyOps Humanize using MiniMax M3. The Git history and planning documents retain the generated implementation evidence. Manual verification confirmed:

  • strict TypeScript typecheck passes;
  • the Vitest suite passes;
  • the production TypeScript build passes.
  • an integration test starts the HTTP server on an ephemeral port and verifies the complete four-tool MCP surface through JSON-RPC;
  • GitHub Actions independently repeats those checks on Node.js 20 and verifies that the committed demo evidence is reproducible.

License

MIT. See LICENSE.

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选