# keyshroud

> keyshroud is an open-source MCP server for security. Gives coding agents your API keys without letting the model ever read them. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** CLI, macOS, Linux, Windows
- **Website:** https://keyshroud.dev
- **Repository:** https://github.com/dinhkarate/keyshroud
- **MCP Registry name:** io.github.dinhkarate/keyshroud
- **Categories:** security, developer tools
- **Listing updated:** 2026-11-14

## About

Secrets sit in an encrypted vault on your machine, or in your own Vaultwarden. When an agent runs a command through `keyshroud run`, the key is injected into the environment, and any occurrence of its value in the output is replaced with a marker like `<redacted:GH_TOKEN>` before the model reads it. A session hook tells the agent which secret names exist, and only names.

In a recorded Claude Code run, the API received the key and returned success, while the key appeared zero times in the saved transcript. The vault's own key goes to the macOS keychain, Linux Secret Service or Windows DPAPI, and `keyshroud import` can move a .env into it.

The author states the limit plainly: it keeps keys out of what the model reads by accident but is not a sandbox against an agent set on stealing one. The MCP server is for clients without a shell.

## Features

- **Injection at run time:** keyshroud run puts secrets into a command's environment.
- **Output masking:** Secret values in output become <redacted:NAME>.
- **Names only to the agent:** A hook lists secret names, not values.
- **Local vault or Vaultwarden:** Encrypted store on your machine or your own server.
- **Plugins for agents:** Plugins for Claude Code and pi, plus MCP.
- **Import from .env:** keyshroud import moves existing secrets.

## Good for

- Let an agent call GitHub or a private API with a token it cannot see
- Stop keys leaking into saved transcripts
- Find a leaked copy of a token in a log
- Give Claude Desktop controlled use of secrets

## Install

### Claude Code (Terminal)

```sh
claude mcp add keyshroud -- npx -y keyshroud
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "keyshroud": {
      "command": "npx",
      "args": [
        "-y",
        "keyshroud"
      ]
    }
  }
}
```

### Cursor (~/.cursor/mcp.json)

```json
{
  "mcpServers": {
    "keyshroud": {
      "command": "npx",
      "args": [
        "-y",
        "keyshroud"
      ]
    }
  }
}
```

### VS Code (.vscode/mcp.json)

```json
{
  "servers": {
    "keyshroud": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "keyshroud"
      ]
    }
  }
}
```

### Windsurf (~/.codeium/windsurf/mcp_config.json)

```json
{
  "mcpServers": {
    "keyshroud": {
      "command": "npx",
      "args": [
        "-y",
        "keyshroud"
      ]
    }
  }
}
```

### Other clients (your client's MCP settings (most use this shape))

```json
{
  "mcpServers": {
    "keyshroud": {
      "command": "npx",
      "args": [
        "-y",
        "keyshroud"
      ]
    }
  }
}
```

## Tools

- `secrets_run`: Runs a command with secrets injected and masks them in output.
- `secrets_list`: Lists secret names.
- `secrets_request`: Requests a secret to be added or approved.
- `vault_status`: Reports the state of the vault.

## FAQ

### Is it a sandbox?

No; the threat model says it prevents accidental exposure, not deliberate theft.

### Do I need an account?

No, the first secret creates a local vault.

### Which Node version?

18.19 or newer.

### Do MCP tools return secrets?

None return a secret value.

### Is keyshroud free?

Yes. keyshroud is open source, so you can use and self-host it for free.

### How do I add keyshroud to Claude Code?

Run this command in your terminal: claude mcp add keyshroud -- npx -y keyshroud

### What are the best alternatives to keyshroud?

The closest alternatives to keyshroud are REA, Codebase Memory, GitHub, Serena MCP: the IDE for your agent and XERJ.

## Alternatives

- [REA](https://ai-powered.com/mcp/rea): REA is an open-source MCP server for developer tools.
- [Codebase Memory](https://ai-powered.com/mcp/codebase-memory): Codebase Memory is an open-source MCP server for knowledge and memory.
- [GitHub](https://ai-powered.com/mcp/github-2): GitHub is an open-source MCP server for developer tools.
- [Serena MCP: the IDE for your agent](https://ai-powered.com/mcp/serena-mcp-the-ide-for-your-agent): Serena MCP: the IDE for your agent is an open-source MCP server for developer tools.
- [XERJ](https://ai-powered.com/mcp/xerj): XERJ is an open-source MCP server for knowledge and memory.
- [Ouroboros](https://ai-powered.com/mcp/ouroboros): Ouroboros is an open-source MCP server for developer tools.
- [Claude Code Ultimate Guide](https://ai-powered.com/mcp/claude-code-ultimate-guide): Claude Code Ultimate Guide is an open-source MCP server for ai models and llm tooling.
- [Concord MCP](https://ai-powered.com/mcp/concord-mcp): Concord MCP is a freemium MCP server for developer tools.

---
Source: https://ai-powered.com/mcp/keyshroud
