Server data from the Official MCP Registry
Protected RAG storage — agents discover public metadata, content only by access token.
About
Protected RAG storage — agents discover public metadata, content only by access token.
Security Report
Valid MCP server (1 strong, 5 medium validity signals). No known CVEs in dependencies. ⚠️ Package registry links to a different repository than scanned source. Imported from the Official MCP Registry. 1 finding(s) downgraded by scanner intelligence.
14 files analyzed · 1 issue found
Security scores are indicators to help you make informed decisions, not guarantees. Always review permissions before connecting any MCP server.
Permissions Required
This plugin requests these system permissions. Most are normal for its category.
What You'll Need
Set these up before or after installing:
Environment variable: KOMA_MASTER_KEY
How to Install
Add this to your MCP configuration file:
{
"mcpServers": {
"io-github-swnotmetal-koma-core-mcp": {
"env": {
"KOMA_MASTER_KEY": "your-koma-master-key-here"
},
"args": [
"-y",
"koma-core-mcp"
],
"command": "npx"
}
}
}Documentation
View on GitHubFrom the project's GitHub README.
Koma
A prompt-injection firewall for Node.js.
Stop malicious prompts before they reach your LLM, tools, or RAG pipeline.
npm install koma-gate
Security primitives distilled from a real AI application. — How Koma was built
What It Stops
| Your app | Attack | Fix | Install |
|---|---|---|---|
| AI chatbot | Prompt injection / jailbreak | Semantic filter blocks attacks before the model | koma-gate |
| Voice AI | Audio abuse / flooding | Validation + rate limiting + geo | koma-scout |
| RAG / search | Data enumeration / scraping | Split index from content, token-gate retrieval | koma-core |
Different attacks cross different boundaries. Koma provides a small primitive for each one.
What Koma Is — and Isn't
Is: composable security primitives · defense-in-depth · usable independently · sits outside the model's authority
Isn't: a model · an agent framework · a replacement for authorization · a magic prompt-injection detector · a complete security boundary by itself
Benchmarks
I threw 1,769 real prompt-injection attacks at Koma Gate in fail-closed mode, using real providers — not mock adapters.
| Provider | Recall | Precision | False Positives |
|---|---|---|---|
| DeepSeek (deepseek-chat) | 98.8% | 100% | 0 |
| Google (gemini-2.5-flash) | 96.2% | 100% | 0 |
Chinese attack set: 100% recall · 100% precision · 0% FPR across 8 categories.
Can you break it? Open an issue with an attack Koma misses. → Full methodology
Quick Start
import { createGeneralKnowledgeGuard } from 'koma-gate';
const guard = createGeneralKnowledgeGuard({
llm: { apiKey: process.env.GEMINI_API_KEY },
});
app.post('/api/chat', guard.middleware(), async (req, res) => {
// Only in-scope requests reach your model
res.json({ reply: await chat(req.body.message) });
});
git clone https://github.com/swnotmetal/Project-Koma
cd Project-Koma && node demo/server.js
curl http://localhost:8080/self-test
Three Defenses
koma-gate — Prompt injection firewall. LLM-based scope classifier that blocks jailbreaks, off-topic requests, and instruction overrides. Supports OpenAI, Anthropic, Google, DeepSeek, and local Ollama models. README →
koma-scout — Perimeter protection. Rate limiting, audio upload validation, geo allowlisting. Cheap checks before expensive AI work. README →
koma-core — Protected RAG storage. Public search index, private content, opaque HKDF-derived tokens. Discovery is not authorization. README →
Each package works standalone. Stack them: Gate filters → Scout throttles → Core stores.
MCP servers — expose Koma to AI agents directly:
koma-gate-mcp—classify_inputtool for prompt-injection checks. README →koma-core-mcp—search_docs+retrieve_docfor protected RAG retrieval. README →
{
"mcpServers": {
"koma-gate": { "command": "npx", "args": ["-y", "koma-gate-mcp"] },
"koma-core": { "command": "npx", "args": ["-y", "koma-core-mcp"] }
}
}
Using an AI coding agent?
Tell it:
"Add Koma to protect this AI endpoint. Use koma-gate for prompt injection, koma-scout for perimeter abuse, and koma-core for protected RAG retrieval. Each works standalone."
Koma is designed for both human and agent discoverability — including two MCP servers. See llms.txt.
Trust & Safety
- Zero runtime dependencies. No supply-chain surface.
- No code execution. Classifies, rate-limits, stores — never executes AI output.
- Fail-closed by default. A broken guard blocks, not passes.
- CodeQL on every push. Targets OWASP LLM01.
- MIT licensed.
→ Security policy · Known limitations · Comparison with alternatives · Contributing
Koma comes from Komainu ("狛犬"), the stone guardian lions of Japanese Shinto shrines. Three defense layers. Each standalone. Patterns distilled from production, not papers.
Reviews
No reviews yet
Be the first to review this server!
More Developer Tools MCP Servers
Fetch
Freeby Modelcontextprotocol · Developer Tools
Web content fetching and conversion for efficient LLM usage
Toleno
Freeby Toleno · Developer Tools
Toleno Network MCP Server — Manage your Toleno mining account with Claude AI using natural language.
mcp-creator-python
Freeby mcp-marketplace · Developer Tools
Create, build, and publish Python MCP servers to PyPI — conversationally.
MarkItDown
Freeby Microsoft · Content & Media
Convert files (PDF, Word, Excel, images, audio) to Markdown for LLM consumption
MCP Marketplace
Freeby mcp-marketplace · Developer Tools
Search and install MCP servers from inside your AI client.
FinAgent
Freeby mcp-marketplace · Finance
Free stock data and market news for any MCP-compatible AI assistant.
