Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIMuseMuseDotsDots+21 more

    safenode mcp gateway

    1

    Implement a secure proxy gateway to enforce policies, audit logs, and human-in-the-loop approvals for MCP tools.

    Free

    1 useSecurity scanned
    safenode mcp gateway

    safenode mcp gateway

    Example session with this skill installed

    I need to secure my filesystem and github MCP tools in Claude Desktop. How do I set up the SafeNode gateway to block dangerous writes but allow read-only tools to fail open?

    • Read your context and instructions
    • Compiled the safenode mcp gateway

    I will now generate the configuration for the SafeNode MCP Gateway and explain how to update your Claude Desktop settings.

    SafeNode Gateway Configuration

    {
      "failMode": "fail_closed",
      "payloadMode": "redacted",
      "logFile": "./safenode-decisions.jsonl",
      "servers": [
        {
          "name": "filesystem",
          "command": "npx",
          "args": ["-y", "@modelcontextprotocol/server-filesystem", "/Users/admin/projects"]
        },
        {
          "name": "github",
          "command": "npx",
          "args": ["-y", "@modelcontextprotocol/server-github"],
          "env": { "GITHUB_PERSONAL_ACCESS_TOKEN": "your_token_here" }
        }
      ],
      "tools": {
        "read_file": { "failMode": "fail_open" },
        "list_files": { "failMode": "fail_open" },
        "search_repositories": { "failMode": "fail_open" }
      }
    }
    

    Next steps

    1. Create a safenode-gateway.json file using the configuration above, ensuring you use absolute paths for the directories and log files.
    2. Update your claude_desktop_config.json by replacing the filesystem and github entries with a single safenode entry pointing to npx safenode-mcp-gateway.
    3. Add your SAFENODE_API_KEY to your system environment variables and restart Claude Desktop to activate enforcement.

    Connects securely to your tools. The creator never sees your data.

    About this skill

    Stop worrying about agents executing dangerous shell commands or deleting database records without oversight. Standard AI agents have direct, unguarded access to your MCP tools, making it impossible to enforce organizational policies or maintain an audit trail.

    This skill implements the SafeNode MCP Gateway, a proxy that sits between your agent client and its MCP servers. It evaluates every tool call against your defined policies before execution. If a tool call is risky, the gateway blocks it or holds it for human review. Because it functions as a proxy rather than a tool itself, the agent cannot choose to bypass the check.

    What it does

    • Enforce guardrails by intercepting tool calls and applying allow, warn, review, or deny logic.
    • Configure fail-safe modes to ensure tool calls are blocked by default if the safety API is unreachable.
    • Redact sensitive data from tool arguments to ensure PII or secrets never leave your local environment.
    • Generate audit logs that record every tool decision and execution attempt for compliance tracking.
    • Proxy multiple servers through a single gateway to centralize security across filesystem, database, and API tools.

    How it works

    1. Inventory existing servers by reading configuration files from Claude Desktop, Claude Code, or Cursor.
    2. Generate gateway configuration including server definitions, fail modes, and data redaction levels.
    3. Perform dry runs to verify what metadata is sent for policy evaluation without making actual network calls.
    4. Update client configuration to route all MCP traffic through the proxy for mandatory enforcement.

    Frameworks & tools

    This skill requires Node.js 18 or newer and uses the safenode-mcp-gateway package. It works with any MCP-compliant host including Claude Desktop, Claude Code, and Cursor.

    Why this beats prompting it yourself

    Manual prompts asking an agent to "be safe" are easily ignored or bypassed by the model. This skill implements a structural proxy that the agent cannot circumvent, providing a hard boundary that functions even if the model is compromised or confused.

    Use cases

    • Restrict filesystem access to specific project directories while blocking system-level modifications.
    • Require human approval for destructive operations like database drops or production deployments.
    • Audit agent activity across team-wide shared tools to maintain security compliance.

    Known limitations

    Requires an active internet connection for policy evaluation and a SafeNode API key. It is not a code sandbox or a prompt injection detector. Policy evaluations count against a monthly API quota.

    Requires Node 18+, internet access for API checks, and a SafeNode account. Does not provide a sandbox environment or detect prompt injection. Call latency is subject to a 5s API timeout.

    How to use

    1. 1

      Connect your agent to the Agensi MCP

      Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup

    2. 2

      Sign in to Agensi

      Your agent shows a sign-in link. Sign in and click Allow.

    3. 3

      Ask for what you need

      Your agent loads this skill and uses it on your task. It always asks before any payment.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill goes through the trust checks below.

    Security scanned

    Checked by our 8-point scan before listing

    1 use

    Times used to date

    Free forever

    No account required to browse

    Trust & safety

    Security scan

    Security scan passed 1 month ago

    • Free with an Agensi account

    Requires

    Safenode Gateway MCP
    Node.js

    Permissions

    Terminal / Shell
    Write Files
    Read Files
    Network Access
    Environment Variables

    File Scopes

    safenode-gateway.json
    .mcp.json
    **/claude_desktop_config.json
    **/.cursor/mcp.json
    safenode-decisions.jsonl

    Reads your existing MCP client config to find your servers, writes safenode-gateway.json, and replaces those entries with a single gateway entry (backing up the original first). Uses the terminal to check Node and dry-run the gateway, which shows exactly what would be sent before anything is. Network access is for npx and the SafeNode policy API. Your API key stays in an environment variable and is never written to a file or requested in chat.

    Listed1 month ago

    What's inside

    Frequently Asked Questions

    Standard agents have direct access to tools, making them prone to 'hallucinating' dangerous actions. This gateway acts as a mandatory structural proxy that intercepts every tool call, ensuring they follow your specific safety policies before they can execute.

    The SafeNode MCP Gateway is compatible with any MCP-compliant host, including Claude Desktop, Claude Code, and Cursor, and can manage multiple MCP servers (filesystem, database, or API) through a single centralized proxy.

    Setup involves three main steps: scanning your existing server configurations, generating a gateway config file with your desired safety rules, and updating your client settings to route traffic through the proxy.

    By default, you can configure 'fail-safe' modes that automatically block any tool execution if the safety API is unreachable, ensuring your system never defaults to an unprotected state.

    Yes, the gateway includes a local redaction feature that allows you to scrub PII or secrets from tool arguments before the metadata is ever sent for policy evaluation.

    This skill provides the implementation logic and configuration templates to deploy the gateway; however, you will need a SafeNode API key and an active internet connection to perform the actual policy evaluations.

    New in LLM Ops