Logo von MCP Secret Wrapper

MCP Secret Wrapper

Organisation
astrix-security

Astrix Security MCP Secret Wrapper

Herausgeberastrix-security
Repositorymcp-secret-wrapper
SpracheTypeScript
Forks
8
Sterne
51
Verfügbare Tools
0
Transporttypstdio
Kategorien
LizenzApache-2.0
Links
  • Tools mit KI-Workflows verbinden

    MCP Secret Wrapper stellt MCP-Funktionen bereit, die kompatible KI-Clients und Agenten nutzen können.

  • 0 verfügbare Tools

    Sehen Sie sich unten die aufrufbaren Aktionen an, einschließlich Namen und Beschreibungen, sofern der Server diese bereitstellt.

  • Konfiguration zum Kopieren

    Nutzen Sie die Installationsbeispiele, um diesen Server in Ihrem bevorzugten MCP-Client zu konfigurieren.

  • Open-Source-Kennzahlen

    51 Sterne und 8 Forks im verlinkten Repository.

License: Apache 2.0

Securely inject secrets from vault systems into MCP (Model Context Protocol) servers without exposing credentials in configuration files.

Usage

Convert any MCP Server configured for your client and uses a static secret in 2 simple steps:

  1. Add the secret to one of the supported vaults
  2. Replace the server's settings in the configuration file to use MCP Secret Wrapper:
    • Run MCP Secret Wrapper with npx
    • Pass any environment variables that should be injected. Their value is the secret location.
    • Place the separator (--) followed by the previous command and all its arguments
    • Add the required VAULT_TYPE environment variable and any additional optional environment variables either in the env section or as CLI arguments (--vault-type). You can find examples of both usages in our Example MCP Server

Example Usage - GitHub MCP with AWS Secret Manager

Before: Config Environment Variable (❌ Insecure - Hardcoded Secret)

json
{
  "mcpServers": {
    "githubApi": {
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "-e",
        "GITHUB_PERSONAL_ACCESS_TOKEN",
        "ghcr.io/github/github-mcp-server"
      ],
      "env": {
        "GITHUB_PERSONAL_ACCESS_TOKEN": "github_pat_EXAMPLE"
      }
    }
  }
}

After: Using Vault (✅ No Exposed Secret)

json
{
  "mcpServers": {
    "githubApi": {
      "command": "npx",
      "args": [
        "-y",
        "@astrixsecurity/mcp-secret-wrapper",
        "GITHUB_PERSONAL_ACCESS_TOKEN=arn:aws:secretsmanager:us-east-1:123456789012:secret:example-ABCDE",
        "--",
        "docker",
        "run",
        "-i",
        "--rm",
        "-e",
        "GITHUB_PERSONAL_ACCESS_TOKEN",
        "ghcr.io/github/github-mcp-server"
      ],
      "env": {
        "VAULT_TYPE": "aws",
        "VAULT_PROFILE": "aws-profile",
        "VAULT_REGION": "us-east-1"
      }
    }
  }
}

https://github.com/user-attachments/assets/9af6e6b3-3694-49de-b107-8749e0630db3

See what's going on behind-the-scenes by using our example MCP server: Example MCP Server

JSON Path Extraction

When your vault stores secrets as JSON objects, you can extract specific values using dot-notation paths. This is useful when a single secret contains multiple values that need to be injected as separate environment variables.

How It Works

Append a # delimiter followed by a JSON path to your secret ID. The path uses dot notation to navigate through nested JSON objects.

Format: SECRET_ID#path.to.value

Example: Database Configuration

Suppose your vault contains a secret with the following JSON structure:

json
{
  "db": {
    "credentials": {
      "username": "demo_user",
      "password": "demo_password"
    },
    "host": "postgres",
    "port": 5432,
    "name": "demo"
  }
}

You can extract individual values using these paths:

  • db.credentials.username - Extracts "demo_user"
  • db.credentials.password - Extracts "demo_password"
  • db.host - Extracts "postgres"
  • db.port - Extracts 5432 (converted to string)

Usage Example

json
{
  "mcpServers": {
    "myServer": {
      "command": "npx",
      "args": [
        "-y",
        "@astrixsecurity/mcp-secret-wrapper",
        "DB_USERNAME=arn:aws:secretsmanager:us-east-1:123456789012:secret:my-db-config#db.credentials.username",
        "DB_PASSWORD=arn:aws:secretsmanager:us-east-1:123456789012:secret:my-db-config#db.credentials.password",
        "DB_HOST=arn:aws:secretsmanager:us-east-1:123456789012:secret:my-db-config#db.host",
        "--",
        "node",
        "/path/to/server.js"
      ],
      "env": {
        "VAULT_TYPE": "aws",
        "VAULT_REGION": "us-east-1"
      }
    }
  }
}

Important Notes

⚠️ Secret ID and the # Delimiter: The # character is used as the delimiter for JSON path extraction.

Why this delimiter? Using # in secret names is generally considered bad practice across vault systems (AWS Secrets Manager, GCP Secrets Manager, etc.), so it's unlikely to appear in real secret IDs. This makes it a safe choice for our delimiter.

What happens if your secret ID contains #?

  • ❌ Without JSON path: If your secret ID is my#secret and you use it without a JSON path (API_KEY=my#secret), the parser will incorrectly split it, treating my as the secret ID and secret as a JSON path. This will cause the lookup to fail.

  • ✅ With JSON path: If your secret ID is my#secret and you use it with a JSON path (API_KEY=my#secret#db.password), it will work correctly because the parser splits on the last # character.

Best practice: Avoid using # in your secret names entirely. This follows vault naming conventions and prevents parsing issues when you're not using JSON path extraction.

Supported Value Types

JSON path extraction supports extracting primitive values:

  • Strings: Returned as-is
  • Numbers: Converted to string representation
  • Booleans: Converted to string ("true" or "false")

Not supported:

  • Arrays
  • Objects (nested objects)
  • null values

If you need to extract a nested object or array, you'll need to store it as a separate secret or use a different approach.

Support

Vault TypeStatusDescription
AWS Secrets Manager✅ SupportedFull support for AWS Secrets Manager with IAM authentication
GCP Secret Manager✅ SupportedFull support for GCP Secret Manager with service account and ADC authentication
HashiCorp Vault🚧 In-ProgressSupport for HashiCorp Vault
Azure Key Vault✅ SupportedFull support for Azure Key Vault with DefaultAzureCredential and service principal authentication

📚 Detailed Documentation: Vault Specific Guides

Why?

MCP servers are becoming the backbone of AI agent infrastructure, but most implementations lead to severe risk by exposing hardcoded credentials. Our analysis of 5,000+ MCP server implementations revealed that over 50% use static, hardcoded API keys and secrets in their configuration files.

The Problem

  • Exposed Credentials: API keys, tokens, and secrets stored in plain text
  • No Rotation: Static credentials that never expire or rotate
  • Access Control: No fine-grained access control
  • Compliance: Violates security best practices and compliance requirements

The Solution

MCP Secret Wrapper provides:

  • Dynamic Secret Retrieval: Secrets are fetched at runtime from secure vaults
  • No Hardcoded Secerts: No secrets are present on the local machine
  • Multi-Vault Support: Works with AWS, HashiCorp, Azure, and Google vaults

Read our research: Blog - An analysis of 5,000 MCP server implementations and their identity security gap.

Contributing

We welcome contributions - this tool can and should be improved by the community. Here's how you can help:

Quick Start

  1. Fork the repository
  2. Create a feature branch: git checkout -b feat/your-feature
  3. Make your changes and add tests
  4. Commit your changes: git commit -m 'Add your feature'
  5. Push to your branch: git push origin feat/your-feature
  6. Open a Pull Request

Adding New Vault Support

  1. Create a new plugin in src/vaults/plugins/
  2. Implement the VaultPlugin interface
  3. Add tests for your implementation
  4. Update the registry and documentation

For more details, see our Contributing Guidelines.

License

This project is licensed under the Apache License 2.0 - see the LICENSE file for details.

Acknowledgements

  • Yuval Sasson - For pioneering the initiative to dynamically retrieve secrets for MCP servers
  • Omer Alon - For developing and releasing the MCP Secert Wrapper tool
  • Oshri Shmuel - For developing and releasing the MCP Secert Wrapper tool
  • Neta Ravid - For developing, releasing, and maintaining the MCP Secret Wrapper tool
  • MCP Community - For creating and maintaining the MCP framework

Installation

TypingMind
Voraussetzungen:

Node.js 18+

{
  "mcpServers": {
    "astrix-security-mcp-secret-wrapper": {
      "command": "npx",
      "args": [
        "-y",
        "@astrixsecurity/mcp-secret-wrapper"
      ]
    }
  }
}

MCP Secret Wrapper MCP mit mehreren KI-Modellen nutzen

TypingMind bindet MCP-Tools auf Arbeitsbereichsebene ein. Sobald MCP Secret Wrapper verbunden ist, können Sie die Integration mit verschiedenen KI-Modellen in TypingMind verwenden, statt sie für jedes Modell separat einzurichten. Diese MCP-Integration läuft lokal über den TypingMind-MCP-Konnektor auf Ihrem Gerät.

Einrichtungsanleitung für den lokalen Konnektor

Nutzen Sie diese Option, wenn der MCP-Server Zugriff auf lokale Dateien, Apps oder private Ressourcen auf Ihrem Computer benötigt.

1

MCP-Einstellungen öffnen

Gehen Sie in TypingMind zu „Einstellungen“, „Erweiterte Einstellungen“ und dann „Model Context Protocol“ und wählen Sie „Konnektor-Setup“.

  1. Öffnen Sie TypingMind in Ihrem Browser.
  2. Klicken Sie auf das Symbol „Optionen“.
  3. Gehen Sie zu „Erweiterte Einstellungen“.
  4. Öffnen Sie den Abschnitt „Model Context Protocol“.
  5. Klicken Sie auf „Konnektor-Setup“ und wählen Sie „Dieses Gerät“.
Einrichtungsbildschirm des TypingMind-MCP-Konnektors mit ausgewählter Option „Dieses Gerät“
2

Konnektor-Befehl ausführen

Wählen Sie „Dieses Gerät“, kopieren Sie den Befehl aus TypingMind und führen Sie ihn im Terminal aus. Lassen Sie den Prozess laufen, solange Sie MCP verwenden.

  1. Kopieren Sie den in TypingMind angezeigten Einrichtungsbefehl.
  2. Öffnen Sie unter macOS Terminal bzw. unter Windows Windows Terminal.
  3. Fügen Sie den Befehl ein und führen Sie ihn aus.
  4. Bestätigen Sie die Paketinstallation, wenn Sie im Terminal zum Fortfahren aufgefordert werden.
  5. Lassen Sie das Terminalfenster geöffnet und den Prozess darin laufen, solange Sie MCP-Tools verwenden.
3

MCP Secret Wrapper als Server hinzufügen

Wenn der Konnektorstatus „Bereit“ anzeigt, klicken Sie auf „Server ändern“ und fügen Sie die MCP-Server-Konfiguration ein.

  1. Warten Sie, bis der Konnektorstatus „Bereit“ anzeigt.
  2. Klicken Sie auf „Server ändern“.
  3. Fügen Sie die MCP-Server-Konfiguration für MCP Secret Wrapper ein.
  4. Speichern Sie die Serverliste.
  5. Aktualisieren Sie die Ansicht, um bei Bedarf zu prüfen, ob der Konnektor weiterhin bereit ist.
MCP-Einstellungen in TypingMind mit aktivem Server und der Schaltfläche „Server ändern“
{
  "mcpServers": {
    "astrix-security-mcp-secret-wrapper": {
      "command": "npx",
      "args": [
        "-y",
        "@astrixsecurity/mcp-secret-wrapper"
      ]
    }
  }
}
4

Verbindung modellübergreifend nutzen

Speichern Sie die Serverliste, öffnen Sie „Plugins“ und aktivieren Sie die MCP-Tools von MCP Secret Wrapper. Wählen Sie dann ein beliebiges unterstütztes KI-Modell in TypingMind und verwenden Sie die Tools im Chat oder weisen Sie sie einem KI-Agenten zu.

  1. Öffnen Sie die Seite „Plugins“ in TypingMind.
  2. Aktivieren Sie die MCP-Tools von MCP Secret Wrapper.
  3. Starten Sie einen Chat und wählen Sie das KI-Modell, das Sie verwenden möchten.
  4. Nutzen Sie die MCP-Tools im Chat oder weisen Sie sie einem KI-Agenten zu.
  5. Wechseln Sie bei Bedarf zu einem anderen KI-Modell, ohne die MCP-Verbindung erneut herzustellen.
TypingMind-Chat mit aktivierten MCP-Tools und einem ausgewählten KI-Modell
Können Sie mir mit MCP Secret Wrapper bei dieser Aufgabe helfen?
MCP Secret Wrapper
Gerne. Ich habe es gelesen.
Das habe ich mit MCP Secret Wrapper gefunden.

Häufig gestellte Fragen

Wofür wird der MCP-Server MCP Secret Wrapper verwendet?

MCP Secret Wrapper ist ein MCP-Server, über den kompatible KI-Clients auf externe Tools und Kontext zugreifen können. In TypingMind können Sie diesen MCP-Server einmal hinzufügen und seine Tools in Ihrem KI-Arbeitsbereich verfügbar machen.

Kann ich MCP Secret Wrapper MCP mit mehreren KI-Modellen in TypingMind verwenden?

Ja. TypingMind bindet MCP-Tools auf Arbeitsbereichsebene ein. So können Sie MCP Secret Wrapper mit verschiedenen KI-Modellen wie Claude, ChatGPT, Gemini oder anderen in TypingMind konfigurierten Modellen verwenden, ohne den MCP-Server für jedes Modell separat einzurichten.

Warum MCP Secret Wrapper MCP mit TypingMind nutzen?

TypingMind ist eine der besten Oberflächen für LLM-Chats, da es mehrere KI-Modelle, Prompts, Plugins, KI-Agenten, API-Schlüssel und MCP-Tools in einem Arbeitsbereich vereint. Sobald MCP Secret Wrapper verbunden ist, können Sie die zugehörigen MCP-Tools mit Ihren bevorzugten Modellen nutzen und Ihre Chat-Abläufe in TypingMind übersichtlich organisieren.

Wie verbinde ich MCP Secret Wrapper MCP mit TypingMind?

MCP Secret Wrapper wird über den lokalen MCP-Konnektor von TypingMind angebunden. Das ist die beste Wahl, wenn der MCP-Server auf lokale Dateien, Desktop-Apps, Befehlszeilentools oder private Ressourcen auf Ihrem Computer zugreifen muss.

Welche Tools stellt MCP Secret Wrapper MCP in TypingMind bereit?

MCP Secret Wrapper stellt MCP-Funktionen bereit, die Sie auf der Plugins-Seite in TypingMind aktivieren und im Chat verwenden oder KI-Agenten zuweisen können.

Muss ich meine API-Schlüssel mit TypingMind teilen, um MCP Secret Wrapper MCP zu verwenden?

Nein. TypingMind arbeitet vorrangig lokal, sodass Sie die Kontrolle über Ihre Modellanbieter, API-Schlüssel, Prompts und MCP-Konfiguration behalten. Falls MCP Secret Wrapper eine Authentifizierung erfordert, fügen Sie beim Erstellen der Verbindung die erforderlichen Header, OAuth-Einstellungen oder die lokale Konfiguration für diesen MCP-Server hinzu.

Ähnliche MCP-Server

Alle

Jetzt eigenen KI-Arbeitsbereich einrichten

Abonnieren Sie unseren Newsletter und erfahren Sie mehr über neue Funktionen und kommende Gewinnspiele 👇