# Valca

> Valca is a free MCP server for security. Read-only security scanner for code, infrastructure files and AI agent config. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Free
- **Platforms:** CLI, vscode, Linux, macOS, Windows
- **Website:** https://valca.io
- **Repository:** https://github.com/pranlabs/valca
- **MCP Registry name:** io.github.pranlabs/valca
- **Categories:** security, developer tools
- **Listing updated:** 2026-11-16

## About

Valca is a security scanner built to catch the insecure defaults AI coding assistants tend to reproduce. The headline example is a docker-compose port mapping such as 5432:5432, which binds to 0.0.0.0 and, because Docker writes its own firewall rules, bypasses UFW. The README says Checkov, Trivy, Snyk and Semgrep miss this, and Valca flags it with the fix of binding to 127.0.0.1.

It ships 116 rules in 27 categories. With Claude Code a hook scans every file before it is saved and blocks the write on critical or high findings, while a scan command, SARIF output and exit codes support CI. This MCP server lets agents call the scanner themselves. It is read-only and never returns the matched line, so a credential it finds does not enter a model's context.

The core engine is offline and stdlib-only Python. Three dependency rules send package names and versions to OSV, PyPI and npm, and can be disabled. Valca is under the Business Source License 1.1, free for production use except as a competing hosted service, and each release converts to MIT after four years.

## Features

- **Generation-time blocking:** Stops insecure writes before the file reaches disk.
- **116 rules:** Covers 27 categories including IaC and agent configuration.
- **Read-only MCP:** Agents can scan but never edit, and matched lines are withheld.
- **CI output:** Exit codes and SARIF feed code-scanning gates.
- **Offline core:** The engine sends no code anywhere; only optional dependency checks use the network.
- **Scan history:** Local log and stats show rule frequency and suppression rates.

## Good for

- Block an exposed database port in docker-compose
- Scan an AI-written project before committing
- Feed SARIF findings to GitHub code scanning
- Check dependencies for known CVEs or fabricated packages

## Install

### Claude Code (Terminal)

```sh
claude mcp add valca -- uvx valca
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "valca": {
      "command": "uvx",
      "args": [
        "valca"
      ]
    }
  }
}
```

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

```json
{
  "mcpServers": {
    "valca": {
      "command": "uvx",
      "args": [
        "valca"
      ]
    }
  }
}
```

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

```json
{
  "servers": {
    "valca": {
      "type": "stdio",
      "command": "uvx",
      "args": [
        "valca"
      ]
    }
  }
}
```

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

```json
{
  "mcpServers": {
    "valca": {
      "command": "uvx",
      "args": [
        "valca"
      ]
    }
  }
}
```

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

```json
{
  "mcpServers": {
    "valca": {
      "command": "uvx",
      "args": [
        "valca"
      ]
    }
  }
}
```

## FAQ

### Does it send my code anywhere?

No. Only package names and versions go out for three dependency rules, which can be disabled.

### What licence is it?

Business Source License 1.1, which the project says is not OSI open source.

### Can the MCP server edit files?

No, it is read-only.

### What happens on a critical finding?

The scan exits with code 2 and Claude Code blocks the write.

### Is Valca free?

Yes. Valca is free to use.

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

Run this command in your terminal: claude mcp add valca -- uvx valca

### What are the best alternatives to Valca?

The closest alternatives to Valca 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/valca
