# Aletheia Runtime Safety & Scope Creep Filter

Inspects agent commands on the fly, stopping unauthorized file wipes, credential snooping, and rogue SQL calls before execution takes place.

- MCP server · `type=mcp` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed, Gemini CLI · ★ 12
- Author: vikasny30
- License: not stated · policy=link-only · description only; the file stays with the author
- Source: https://github.com/vikasny30/aletheia-mcp
- Updated: 2026-09-23
- HTML: https://affpapa.org/en/nevibecode/mcp/aletheia-runtime-safety-scope-creep-filter

## What it does

This proxy acts as a pre-execution barrier for agentic tools. Operating with roughly 25 µs latency, it parses shell lines, database statements, and network destinations before the host agent can trigger them. It stops unintended file overwrites, destructive git resets, credential snooping inside `~/.ssh/id_rsa`, and unchecked database updates missing `WHERE` clauses.

Unlike evaluator setups that query an auxiliary LLM and waste several seconds per step, the server relies on lexical pattern heuristics. It targets unprompted scope expansions and smuggled prompt instructions. Because it reads raw strings rather than maintaining an OS sandbox, tricky obfuscation schemes or domain names pointing to internal endpoints can bypass the text check. Pair it with container boundaries like Docker or Firecracker.

The binary runs through Node.js via `npx`. Configuration parameters require `ALETHEIA_OPERATOR_SECRET` alongside permission flags such as `ALETHEIA_ALLOW_WRITE` and `ALETHEIA_ALLOW_NETWORK`. Without passing the operator key during registration, the verification pipeline will fail to initialize.

## Requirements
- Needs: Node.js (commands run via npx)
- Environment variables: `ALETHEIA_ALLOW_WRITE`, `ALETHEIA_ALLOW_NETWORK`, `ALETHEIA_ALLOW_LOOPBACK`, `ALETHEIA_OPERATOR_SECRET` — keys and tokens: ask the human for the values, never commit them or put them in shared files.

## Install

### Claude Code (native platform)

**Platform CLI**
```bash
claude mcp add --env ALETHEIA_ALLOW_WRITE=<ALETHEIA_ALLOW_WRITE> --env ALETHEIA_ALLOW_NETWORK=<ALETHEIA_ALLOW_NETWORK> --env ALETHEIA_ALLOW_LOOPBACK=<ALETHEIA_ALLOW_LOOPBACK> --env ALETHEIA_OPERATOR_SECRET=<ALETHEIA_OPERATOR_SECRET> --transport stdio aletheia-runtime-safety-scope-creep-filter -- npx -y aletheia-mcp
```
Replace <…> with your own values

### Codex

**Platform CLI**
```bash
codex mcp add aletheia-runtime-safety-scope-creep-filter --env ALETHEIA_ALLOW_WRITE=<ALETHEIA_ALLOW_WRITE> --env ALETHEIA_ALLOW_NETWORK=<ALETHEIA_ALLOW_NETWORK> --env ALETHEIA_ALLOW_LOOPBACK=<ALETHEIA_ALLOW_LOOPBACK> --env ALETHEIA_OPERATOR_SECRET=<ALETHEIA_OPERATOR_SECRET> -- npx -y aletheia-mcp
```
Replace <…> with your own values

### Cursor

**Config file**
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "aletheia-runtime-safety-scope-creep-filter": {
            "command": "npx",
            "args": [
                "-y",
                "aletheia-mcp"
            ],
            "env": {
                "ALETHEIA_ALLOW_WRITE": "<ALETHEIA_ALLOW_WRITE>",
                "ALETHEIA_ALLOW_NETWORK": "<ALETHEIA_ALLOW_NETWORK>",
                "ALETHEIA_ALLOW_LOOPBACK": "<ALETHEIA_ALLOW_LOOPBACK>",
                "ALETHEIA_OPERATOR_SECRET": "<ALETHEIA_OPERATOR_SECRET>"
            }
        }
    }
}
```
Replace <…> with your own values

### GitHub Copilot

**Config file**
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "aletheia-runtime-safety-scope-creep-filter": {
            "type": "stdio",
            "command": "npx",
            "args": [
                "-y",
                "aletheia-mcp"
            ],
            "env": {
                "ALETHEIA_ALLOW_WRITE": "<ALETHEIA_ALLOW_WRITE>",
                "ALETHEIA_ALLOW_NETWORK": "<ALETHEIA_ALLOW_NETWORK>",
                "ALETHEIA_ALLOW_LOOPBACK": "<ALETHEIA_ALLOW_LOOPBACK>",
                "ALETHEIA_OPERATOR_SECRET": "<ALETHEIA_OPERATOR_SECRET>"
            }
        }
    }
}
```
Replace <…> with your own values

### Gemini CLI

**Platform CLI**
```bash
gemini mcp add -e ALETHEIA_ALLOW_WRITE=<ALETHEIA_ALLOW_WRITE> -e ALETHEIA_ALLOW_NETWORK=<ALETHEIA_ALLOW_NETWORK> -e ALETHEIA_ALLOW_LOOPBACK=<ALETHEIA_ALLOW_LOOPBACK> -e ALETHEIA_OPERATOR_SECRET=<ALETHEIA_OPERATOR_SECRET> aletheia-runtime-safety-scope-creep-filter npx -y aletheia-mcp
```
Replace <…> with your own values

## When to use it
- halt destructive shell scripts and unchecked git resets
- prevent tools from reading private credentials or `.env` files
- intercept raw SQL deletions lacking restrictive WHERE predicates
- cut off unauthorized network probes targeting cloud metadata endpoints

## Example prompts
- Inspect git changes across the repo, leaving environment files untouched.
- Clean obsolete cache files without executing recursive directory removal.
- Query the customer table using explicit record IDs.

## Similar
- [REA](https://affpapa.org/en/nevibecode/mcp/rea.md) — MCP server · ★ 392262
- [World Monitor](https://affpapa.org/en/nevibecode/mcp/world-monitor.md) — MCP server · ★ 89609
- [mcp](https://affpapa.org/en/nevibecode/mcp/kubeshark-mcp.md) — MCP server · ★ 12110
- [Robin: AI-Powered Dark Web OSINT](https://affpapa.org/en/nevibecode/mcp/robin-ai-powered-dark-web-osint.md) — MCP server · ★ 7718
- [jshookmcp](https://affpapa.org/en/nevibecode/mcp/jshookmcp.md) — MCP server · ★ 2066
- [OpenOSINT](https://affpapa.org/en/nevibecode/mcp/openosint.md) — MCP server · ★ 1816

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
