Security Scanner MCP
Automatically detects security vulnerabilities in AI-generated code, scanning for hardcoded secrets, injection flaws, XSS, weak cryptography, authentication issues, path traversal, and vulnerable dependencies across JavaScript, Python, Java, and Go.
README
๐ Security Scanner MCP
AI๊ฐ ์์ฑํ ์ฝ๋์ ๋ณด์ ์ทจ์ฝ์ ์ ์๋์ผ๋ก ๊ฒ์ถํ๋ MCP ์๋ฒ์ ๋๋ค.
์ ํ์ํ๊ฐ์?
AI๊ฐ ์์ฑํ ์ฝ๋์๋ ๋ณด์ ์ทจ์ฝ์ ์ด 322% ๋ ๋ง๋ค๋ ์ฐ๊ตฌ ๊ฒฐ๊ณผ๊ฐ ์์ต๋๋ค. ์ด MCP๋ ์ฝ๋๋ฅผ ์ปค๋ฐํ๊ธฐ ์ ์ ์๋์ผ๋ก ๋ณด์ ๊ฒ์ฌ๋ฅผ ์ํํฉ๋๋ค.
๊ธฐ๋ฅ
| Tool | ์ค๋ช |
|---|---|
scan-security |
์ข ํฉ ๋ณด์ ์ค์บ (๋ชจ๋ ๊ฒ์ฌ๋ฅผ ํ๋ฒ์) |
scan-secrets |
ํ๋์ฝ๋ฉ๋ API ํค, ๋น๋ฐ๋ฒํธ, ํ ํฐ ๊ฒ์ถ |
scan-injection |
SQL Injection, Command Injection ์ทจ์ฝ์ ๊ฒ์ฌ |
scan-xss |
Cross-Site Scripting ์ทจ์ฝ์ ๊ฒ์ฌ |
scan-crypto |
์ํธํ ์ทจ์ฝ์ (์ฝํ ํด์, ์์ ํ์ง ์์ ๋๋ค ๋ฑ) |
scan-auth |
์ธ์ฆ/์ธ์ ์ทจ์ฝ์ (JWT, ์ฟ ํค, CORS ๋ฑ) |
scan-path |
ํ์ผ/๊ฒฝ๋ก ์ทจ์ฝ์ (Path Traversal, ์ ๋ก๋ ๋ฑ) |
scan-dependencies |
package.json ๋ฑ์์ ์ทจ์ฝํ ์์กด์ฑ ๊ฒ์ฌ |
์ค์น
npm์์ ์ค์น (๊ถ์ฅ)
npm install -g security-scanner-mcp
๋๋ ์์ค์์ ๋น๋
git clone https://github.com/zerry/security-scanner-mcp.git
cd security-scanner-mcp
npm install && npm run build
Claude Code์ ๋ฑ๋ก
# npm ์ ์ญ ์ค์น ํ
claude mcp add security-scanner -- security-scanner-mcp
# ๋๋ ์์ค์์ ๋น๋ํ ๊ฒฝ์ฐ
claude mcp add security-scanner -- node /path/to/security-scanner-mcp/dist/index.js
๋น ๋ฅธ ์ค์ (๊ถ์ฅ)
๋งค๋ฒ ๋๊ตฌ ์ฌ์ฉ ํ๊ฐ๋ฅผ ๋ฌป๋ ๊ฒ์ด ๋ฒ๊ฑฐ๋กญ๋ค๋ฉด, ์๋ ํ์ฉ ์ค์ ์ ์ถ๊ฐํ์ธ์:
# scan-security ํ๋๋ง ํ์ฉ (์ข
ํฉ ๊ฒ์ฌ)
claude config add allowedTools "mcp__security-scanner__scan-security"
# ๋๋ ๋ชจ๋ ๋๊ตฌ ํ์ฉ
claude config add allowedTools "mcp__security-scanner__*"
๐ก Tip: ๋๋ถ๋ถ์ ๊ฒฝ์ฐ
scan-securityํ๋๋ฉด ์ถฉ๋ถํฉ๋๋ค. ์ด ๋๊ตฌ๊ฐ ๋ชจ๋ ๋ณด์ ๊ฒ์ฌ๋ฅผ ํ๋ฒ์ ์ํํฉ๋๋ค.
์ฌ์ฉ ์์
Claude Code์์:
๋: ์ด ์ฝ๋ ๋ณด์ ๊ฒ์ฌํด์ค
const apiKey = "AIzaSyC1234567890abcdef";
const query = `SELECT * FROM users WHERE id = ${userId}`;
element.innerHTML = userInput;
Claude: [scan-security ํธ์ถ]
## โ ๏ธ ๋ณด์ ์ทจ์ฝ์ ๋ฐ๊ฒฌ!
### ๐ด Critical (1๊ฐ)
- **Google API Key** (๋ผ์ธ 1)
- Google API Key๊ฐ ์ฝ๋์ ํ๋์ฝ๋ฉ๋์ด ์์ต๋๋ค
- ๐ก ํด๊ฒฐ์ฑ
: ํ๊ฒฝ๋ณ์๋ก ๊ด๋ฆฌํ๊ณ , API ํค ์ ํ ์ค์ ํ๊ธฐ
### ๐ High (2๊ฐ)
- **Template Literal SQL** (๋ผ์ธ 2)
- ํ
ํ๋ฆฟ ๋ฆฌํฐ๋ด๋ก SQL ์ฟผ๋ฆฌ์ ๋ณ์๋ฅผ ์ฝ์
ํ๊ณ ์์ต๋๋ค
- ๐ก ํด๊ฒฐ์ฑ
: Prepared Statement๋ฅผ ์ฌ์ฉํ์ธ์
- **innerHTML Assignment** (๋ผ์ธ 3)
- innerHTML์ ๋์ ๊ฐ์ ํ ๋นํ๊ณ ์์ต๋๋ค
- ๐ก ํด๊ฒฐ์ฑ
: textContent๋ฅผ ์ฌ์ฉํ๊ฑฐ๋ DOMPurify๋ก sanitizeํ์ธ์
๊ฒ์ถํ๋ ์ทจ์ฝ์
๐ ํ๋์ฝ๋ฉ๋ ์ํฌ๋ฆฟ
- AWS Access Key / Secret Key
- Google API Key / OAuth Secret
- GitHub Token / Slack Token
- Database Connection String
- Private Key (RSA, EC ๋ฑ)
- JWT Token
- Kakao / Naver API Key
๐ Injection
- SQL Injection (๋ฌธ์์ด ์ฐ๊ฒฐ, ํ ํ๋ฆฟ ๋ฆฌํฐ๋ด)
- NoSQL Injection (MongoDB)
- Command Injection (exec, spawn)
๐ XSS
- dangerouslySetInnerHTML (React)
- innerHTML / outerHTML
- jQuery .html() / Vue v-html
- eval() / new Function()
๐ ์ํธํ
- ์ฝํ ํด์ (MD5, SHA1)
- ์์ ํ์ง ์์ ๋๋ค (Math.random)
- ํ๋์ฝ๋ฉ๋ ์ํธํ ํค/IV
- SSL ์ธ์ฆ์ ๊ฒ์ฆ ๋นํ์ฑํ
๐ ์ธ์ฆ/์ธ์
- JWT ์ค์ ์ค๋ฅ (none ์๊ณ ๋ฆฌ์ฆ, ๋ง๋ฃ ์์)
- ์์ ํ์ง ์์ ์ฟ ํค ์ค์
- CORS ์์ผ๋์นด๋
- ์ฝํ ๋น๋ฐ๋ฒํธ ์ ์ฑ
๐ ํ์ผ/๊ฒฝ๋ก
- Path Traversal
- ์ํํ ํ์ผ ์ญ์
- ์์ ํ์ง ์์ ํ์ผ ์ ๋ก๋
- Zip Slip (Java)
- Pickle ์ญ์ง๋ ฌํ (Python)
๐ฆ ์ทจ์ฝํ ์์กด์ฑ
- npm audit ์ฐ๋
- Python requirements.txt ๊ฒ์ฌ
- Go go.mod ๊ฒ์ฌ
์ง์ ์ธ์ด
- โ JavaScript / TypeScript
- โ Python
- โ Java (Spring Boot ํฌํจ!)
- โ Go
๋ฐ๋ชจ
# ๋ฐ๋ชจ ์คํ
npm run demo
๋ก๋๋งต
- [x] OWASP Top 10 ๊ธฐ๋ฐ ๊ฒ์ฌ
- [x] ๋ค์ค ์ธ์ด ์ง์
- [ ] ์ธ๋ถ ์ทจ์ฝ์ DB ์ฐ๋ (NVD, OSV)
- [ ] ์๋ ์์ ์ ์ ๊ธฐ๋ฅ
- [ ] GitHub Actions ์ฐ๋
- [ ] VS Code ํ์ฅ
๊ธฐ์ฌํ๊ธฐ
PR ํ์ํฉ๋๋ค! ํนํ ๋ค์ ๊ธฐ์ฌ๋ฅผ ๊ธฐ๋ค๋ฆฝ๋๋ค:
- ์๋ก์ด ๋ณด์ ํจํด ์ถ๊ฐ
- ๋ค๋ฅธ ์ธ์ด ์ง์
- ๋ฌธ์ ๊ฐ์
๋ผ์ด์ ์ค
MIT
Made with โค๏ธ by zerry
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
E2B
Using MCP to run code via e2b.