# VeraCrypt MCP server

> Allows an AI client to mount and unmount VeraCrypt containers using secure stdin password handling and OS keyring integration.

- Repository: https://github.com/bitterdev/veracrypt-mcp
- Page: https://hostedmcp.org/servers/bitterdev/veracrypt-mcp
- Transport: stdio
- Stars: 1
- License: MIT
- Latest version: 0.2.0

## Install

### Claude Code

```sh
claude mcp add veracrypt-mcp -- uvx veracrypt-mcp
```

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

```json
{
  "mcpServers": {
    "veracrypt-mcp": {
      "command": "uvx",
      "args": [
        "veracrypt-mcp"
      ]
    }
  }
}
```

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

```json
{
  "servers": {
    "veracrypt-mcp": {
      "type": "stdio",
      "command": "uvx",
      "args": [
        "veracrypt-mcp"
      ]
    }
  }
}
```

### VS Code CLI

```sh
code --add-mcp '{"name":"veracrypt-mcp","type":"stdio","command":"uvx","args":["veracrypt-mcp"]}'
```

### Claude Desktop (`claude_desktop_config.json`)

```json
{
  "mcpServers": {
    "veracrypt-mcp": {
      "command": "uvx",
      "args": [
        "veracrypt-mcp"
      ]
    }
  }
}
```

### Codex

```sh
codex mcp add veracrypt-mcp -- uvx veracrypt-mcp
```

### Codex config.toml (`~/.codex/config.toml`)

```toml
[mcp_servers.veracrypt-mcp]
command = "uvx"
args = ["veracrypt-mcp"]
```

### Gemini CLI

```sh
gemini mcp add -s user veracrypt-mcp uvx -- veracrypt-mcp
```

### Gemini settings.json (`~/.gemini/settings.json`)

```json
{
  "mcpServers": {
    "veracrypt-mcp": {
      "command": "uvx",
      "args": [
        "veracrypt-mcp"
      ]
    }
  }
}
```

## Environment variables

| Name | Required | Secret | Description |
|---|---|---|---|
| `VERACRYPT_MCP_CONTAINER` | no | no |  |
| `VERACRYPT_MCP_KEYCHAIN_ACCOUNT` | no | no |  |

## FAQ

### How does the server handle passwords securely?

The server pipes the password to VeraCrypt via stdin using the official --stdin option, ensuring passwords are never visible in the process list.

### What is the recommended way to manage passwords?

It is recommended to store the password in the OS keyring (macOS Keychain or Linux libsecret) so the password never enters the LLM context.

### Can I use hardware tokens like YubiKey?

Yes, you can set a VERACRYPT_MCP_UNLOCK_COMMAND for keyfiles that require a hardware token unlock.
