安全審計工具
一個強大的 MCP(模型上下文協議)伺服器,用於審核 npm 套件依賴的安全漏洞。內建遠端 npm 註冊中心整合,實現即時安全檢查。
概覽
什麼是 MCP 安全審計?
MCP 安全審計是一個強大的工具,旨在審計 npm 套件依賴的安全漏洞。它利用模型上下文協議(MCP)來確保開發人員能夠通過識別其依賴中的潛在風險來維護安全的應用程序。該工具與遠程 npm 註冊表無縫集成,允許實時安全檢查,並為開發人員提供有關其套件安全狀態的即時反饋。
MCP 安全審計的特點
- 實時安全檢查:與遠程 npm 註冊表的集成使得套件依賴的即時安全評估成為可能。
- 全面的漏洞報告:MCP 安全審計提供有關識別到的漏洞的詳細報告,包括嚴重性級別和建議行動。
- 用戶友好的界面:該工具以可用性為設計考量,使開發人員能夠輕鬆導航並理解其項目的安全狀態。
- 開源:作為一個公共模板,開發人員可以為其改進做出貢獻,並根據自己的需求進行自定義。
- 社區支持:擁有活躍的用戶和貢獻者社區,開發人員可以尋求幫助並分享有關安全實踐的見解。
如何使用 MCP 安全審計
-
安裝:首先通過 npm 安裝 MCP 安全審計工具。使用以下命令:
npm install mcp-security-audit
-
執行審計:安裝後,導航到您的項目目錄並運行審計命令:
mcp-security-audit
-
審查報告:審計完成後,查看生成的報告。它將列出所有發現的漏洞,按嚴重性分類。
-
採取行動:根據報告中提供的建議來解決漏洞。這可能包括更新套件、刪除未使用的依賴或應用補丁。
-
持續監控:定期運行審計作為開發工作流程的一部分,以確保持續的安全合規性。
常見問題
MCP 安全審計可以檢測哪些類型的漏洞?
MCP 安全審計可以檢測各種漏洞,包括過時的套件、已知的安全缺陷和您 npm 依賴中的潛在利用。
MCP 安全審計是免費使用的嗎?
是的,MCP 安全審計是一個開源工具,免費使用。開發人員也可以為其開發和改進做出貢獻。
我應該多久運行一次審計?
建議定期運行審計,特別是在添加新依賴或更新現有依賴後。將其集成到您的 CI/CD 管道中可以幫助維持安全標準。
我可以自定義審計報告嗎?
是的,該工具允許根據您項目的特定需求自定義報告。您可以修改輸出格式和報告中包含的詳細程度。
我可以在哪裡找到有關 MCP 安全審計的更多信息?
有關更多詳細信息、文檔和社區支持,請訪問官方網站 mcpdirs.com。
詳細
Security Audit Tool
<a href="https://glama.ai/mcp/servers/jjnmdxzmeu"> <img width="380" height="200" src="https://glama.ai/mcp/servers/jjnmdxzmeu/badge" /> </a>A powerful MCP (Model Context Protocol) Server that audits npm package dependencies for security vulnerabilities. Built with remote npm registry integration for real-time security checks.
Features
- 🔍 Real-time security vulnerability scanning
- 🚀 Remote npm registry integration
- 📊 Detailed vulnerability reports with severity levels
- 🛡️ Support for multiple severity levels (critical, high, moderate, low)
- 📦 Compatible with npm/pnpm/yarn package managers
- 🔄 Automatic fix recommendations
- 📋 CVSS scoring and CVE references
Installing via Smithery
To install Security Audit Tool for Claude Desktop automatically via Smithery:
npx -y @smithery/cli install @qianniuspace/mcp-security-audit --client claude
MCP Integration
Option 1: Using NPX (Recommended)
- Add MCP configuration to Cline /Cursor:
{
"mcpServers": {
"mcp-security-audit": {
"command": "npx",
"args": ["-y", "mcp-security-audit"]
}
}
}
Option 2: Download Source Code and Configure Manually
- Clone the repository:
git clone https://github.com/qianniuspace/mcp-security-audit.git
cd mcp-security-audit
- Install dependencies and build:
npm install
npm run build
- Add MCP configuration to Cline /Cursor :
{
"mcpServers": {
"mcp-security-audit": {
"command": "npx",
"args": ["-y", "/path/to/mcp-security-audit/build/index.js"]
}
}
}
Configuration Screenshots
Cursor Configuration
Cline Configuration
API Response Format
The tool provides detailed vulnerability information including severity levels, fix recommendations, CVSS scores, and CVE references.
Response Examples
1. When Vulnerabilities Found (Severity-response.json)
{
"content": [{
"vulnerability": {
"packageName": "lodash",
"version": "4.17.15",
"severity": "high",
"description": "Prototype Pollution in lodash",
"cve": "CVE-2020-8203",
"githubAdvisoryId": "GHSA-p6mc-m468-83gw",
"recommendation": "Upgrade to version 4.17.19 or later",
"fixAvailable": true,
"fixedVersion": "4.17.19",
"cvss": {
"score": 7.4,
"vector": "CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N"
},
"cwe": ["CWE-1321"],
"url": "https://github.com/advisories/GHSA-p6mc-m468-83gw"
},
"metadata": {
"timestamp": "2024-04-23T10:00:00.000Z",
"packageManager": "npm"
}
}]
}
2. When No Vulnerabilities Found (no-Severity-response.json)
{
"content": [{
"vulnerability": null,
"metadata": {
"timestamp": "2024-04-23T10:00:00.000Z",
"packageManager": "npm",
"message": "No known vulnerabilities found"
}
}]
}
Development
For development reference, check the example response files in the public
directory:
- Severity-response.json : Example response when vulnerabilities are found (transformed from npm audit API response)
- no-Severity-response.json : Example response when no vulnerabilities are found (transformed from npm audit API response)
Note: The example responses shown above are transformed from the raw npm audit API responses to provide a more structured format. The original npm audit API responses contain additional metadata and may have a different structure.
Contributing
Contributions are welcome! Please read our Contributing Guide for details on our code of conduct and the process for submitting pull requests.
License
This project is licensed under the MIT License - see the LICENSE file for details.
Author
ESX (qianniuspace@gmail.com)
Links
伺服器配置
{
"mcpServers": {
"mcp-security-audit": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"ghcr.io/metorial/mcp-container--qianniuspace--mcp-security-audit--mcp-security-audit",
"node ./build/index.js"
],
"env": {}
}
}
}