McpGuard
The security layer between your AI agent and its tools.
Brand: Tunedness
McpGuard is a security proxy that sits between an AI client and the MCP servers it uses. Your agents’ tool calls and tool responses pass through this layer; McpGuard scans them, masks them, applies rules to them and records them. It is one of Tunedness’s open source projects.
What it does
Injection scanning. A deterministic engine looks for signature rules, imperative mood, hidden Unicode characters and encoded payloads (decoded and scanned again); it also catches egress beacons and chat-frame injection. Turkish and English are supported, and it holds up against deasciified spelling and homoglyphs.
PII masking. Turkish ID number, tax number, IBAN, card number (checksum-verified), phone and e-mail are masked in the form [KIND:***].
Access control. Allow or deny per tool, roles, and dangerous capability combinations are defined in policy.
Manifest pinning. A server’s tool definitions are trusted on first use and locked with a hash; if they change later (a rug-pull), it is noticed.
Audit log. A hash-chained JSONL log is tamper-evident; masked content and a keyed fingerprint are stored instead of raw content.
Observe first, then enforce
The init command generates a starter policy (guardpolicy.yaml) in observe mode. wrap wraps an MCP server, scan scans a file, and audit verify checks the integrity of the audit log. Telemetry (OTLP) is optional and off by default. McpGuard can be chained with AgentFuse from the same organization; in the chain it is the outermost proxy.
Installation and scope
McpGuard is installed from its GitHub repository: you clone it and build it. There is no package published on npm yet. Node.js 20.19 or later is required. Left out on purpose and planned for later: a guarded HTTP gateway, health-data (PHI) masking and a local SLM judge.
License
Apache-2.0. The source is developed on GitHub.
Key features
- Prompt-injection scanning: signature rules, hidden Unicode, encoded payloads, Turkish and English
- PII masking: Turkish ID number, tax number, IBAN, card, phone, e-mail
- Per-tool allow and deny rules with role-based access
- Manifest pinning: trust on first use, hash lock, rug-pull detection
- Hash-chained, tamper-evident audit log
- The starter policy blocks nothing; PII is masked and the audit log is on
Frequently asked questions
What does McpGuard do?+
It is a security proxy that sits between an AI client and its MCP servers. It scans the traffic for prompt injection, masks personal data, restricts tool access and writes what happened to an audit log.
How is it installed?+
McpGuard is installed from its GitHub repository: you clone it, build it and run the command-line tool locally. There is no package published on npm yet.
Does it start blocking things right away?+
No. The starter policy is in observe mode: nothing is blocked, personal data is masked and the audit log is on. You turn blocking on yourself.
Does the audit log store raw content?+
No. The log is a hash-chained JSONL file and keeps masked content plus a keyed fingerprint instead of the raw content.
Does it send telemetry?+
Telemetry is optional and off by default.
What is the license?+
Apache-2.0. It is open source; the code is on GitHub.
Let’s build your next project together
Tell us your idea and we’ll design the right solution for you.
Get in touch