Skip to main content
Glama
ai-security-gateway-mcp

ai-security-gateway-mcp

by dceptev-byte

AI Security Gateway β€” MCP Server

Local PII detection and masking for Claude Desktop, Cursor, and Windsurf. Your prompts are scanned on your machine before reaching any LLM.

What it does

Automatically detects and masks sensitive data in your prompts:

  • πŸ“§ Email addresses

  • πŸ“± Phone numbers (India-friendly)

  • πŸ’³ Credit card numbers

  • πŸͺͺ Aadhaar numbers

  • πŸ“‹ PAN cards

  • 🌐 IP addresses

  • πŸ›‚ Passport numbers

  • 🏦 Bank account numbers

Related MCP server: privacyscrubber-mcp

How it works

Once installed, Claude Desktop (and Cursor/Windsurf) automatically has access to a scan_prompt tool. You can ask Claude to scan any prompt before sending it, or Claude will proactively suggest scanning when it detects potentially sensitive content.

Installation

Option 1 β€” Run directly with npx (no install needed)

Add to your claude_desktop_config.json:

{
  "mcpServers": {
    "ai-security-gateway": {
      "command": "npx",
      "args": ["-y", "ai-security-gateway-mcp"]
    }
  }
}

Option 2 β€” Install globally

npm install -g ai-security-gateway-mcp

Then add to claude_desktop_config.json:

{
  "mcpServers": {
    "ai-security-gateway": {
      "command": "ai-security-gateway-mcp"
    }
  }
}

Config file locations

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json

  • Windows: %APPDATA%\Claude\claude_desktop_config.json

Usage

After restarting Claude Desktop, try:

Scan this prompt for PII before I send it: [your text here]
Use REPLACE mode to anonymize: [your text here]
Is this safe to send to an LLM? [your text here]

Anonymization modes

Mode

Behaviour

Example

MASK

Partially hides values

j***@g***.com

REDACT

Removes values entirely

(empty)

REPLACE

Substitutes typed tokens

[EMAIL], [AADHAAR]

Works with

  • Claude Desktop (macOS and Windows)

  • Cursor

  • Windsurf

  • Any MCP-compatible client

Privacy

All detection runs locally on your machine. No data is sent to any server or cloud service.

Development

npm install
npm run build   # compile TypeScript β†’ dist/
npm run dev     # run via tsx (no compile step)
npm start       # run compiled output

Available Tools

1 tool
scan_promptA

Scans text for PII (personally identifiable information) before sending to an LLM. Detects emails, phone numbers, credit cards, Aadhaar numbers, PAN cards, IP addresses, passports, and bank accounts. Returns risk level, findings, and anonymized text. Always run this before sending sensitive prompts to any LLM.

Inputs: text (required), mode.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4.1/5.0

    Scored across 1 tool

    Disambiguation5/5

    With only one tool, there is no possibility of confusion between tools. The single tool's purpose is clearly defined and distinct.

    Naming Consistency5/5

    The tool name 'scan_prompt' follows a clear verb_noun convention, which is consistent even though there is only one tool. No conflicting naming styles are present.

    Tool Count2/5

    The server is named 'ai-security-gateway', implying a broader set of security functions, but it exposes only a single tool. This feels far too thin for the apparent scope, which likely requires multiple operations like output scanning or configuration.

    Completeness1/5

    The server only scans input prompts for PII and anonymizes them. It lacks other critical gateway features such as output scanning, response filtering, or policy management, making the surface severely incomplete for a security gateway.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      B
      quality
      B
      maintenance
      Zero-Trust local PII & secrets masking MCP (ZTDS RFC v1.0). Zero server logs. Features: 23 zero-trust tools, 30 industry profiles, offline OCR, RAM-only masking. Run: npx -y @privacyscrubber/mcp-server. Website: https://privacyscrubber.com SDK: https://www.npmjs.com/package/@privacyscrubber/sdk
      4
      23
      723 npm
      3
      MIT
    • A
      license
      A
      quality
      C
      maintenance
      Detects and redacts sensitive personal information such as names, emails, phone numbers, ID numbers, and locations in text before it is processed by AI agents, using configurable mask, hash, or remove strategies.
      1
      MIT
    • F
      license
      Not graded
      quality
      B
      maintenance
      Enables reversible anonymization of sensitive PII such as SSNs, credit cards, passport numbers, emails, and phone numbers before sending prompts to external LLMs, then restores original values locally using HMAC isolation.
      7
      -