Local MCP code-execution sandbox · MIT
Run untrusted AI-agent code in a kernel-isolated sandbox on your own machine.
Free, local, and auditable — one runtime dependency, no cloud sandbox vendor, no per-second bill.
uv tool install vestibule-mcp
Not a VM — shares the host kernel on Linux; sandboxes only code sent to run_code.
Read SECURITY.md
/workspace and connects to 1.1.1.1:80), then inside Vestibule (blocked on both, reporting isolation: native under WSL2). Right: vestibule-mcp ui shows the run live.
01 / Live Inspector
Local Inspector Preview (vestibule-mcp ui)
Interactive preview populated with sample audit records so you can explore the read-only local dashboard without installing anything. Run vestibule-mcp ui on your own machine to inspect live runs and /workspace on 127.0.0.1.
02 / Setup
Setup & Config Wizard
Pick your platform, MCP client, and optional limits for exact prerequisites, install commands, and config JSON. Runs offline with zero external requests.
03 / Architecture
Inside the Isolation Chamber
Native Linux isolation below (no Docker, no root). On Windows, macOS, and stock Ubuntu 23.10+, Vestibule runs a locked-down throwaway container instead.
Clean MCP Server
Receives tool calls from your AI agent and never runs untrusted code in its own process.
- Validates the language (Python, Node, or Bash), code size, and timeout before starting any sandbox.
- Returns readable
Blocked:replies instead of crashing your agent session. - Writes every call to a local audit log (code, isolation status, and usage — never output contents).
Unprivileged Sandbox Supervisor
Starts a fresh, non-root supervisor process outside the sandbox for every run.
- Applies per-run memory (no swap), CPU, and process limits before any untrusted code starts.
- Builds the syscall allowlist and isolates user and process views without root privileges.
- Enforces timeouts from outside so runaway code cannot block cleanup, then records final usage.
Sealed Inner Chamber
Locks down the sandbox from the inside right before launching the agent's code.
- Replaces the filesystem view so only pinned runtimes, a capped
/tmp, and/workspaceexist inside. - Cuts off all network access and permanently drops every Linux privilege.
- Loads the syscall filter, runs self-checks, and cleans up every child process on exit.
Isolated Code & One Doorway
Untrusted Python, Node, or Bash runs inside the sealed chamber with /workspace as its only shared folder.
- Host files outside
/workspacedo not exist inside the sandbox, and all outbound network calls fail immediately. read_workspaceandvestibule-mcp uiinspect/workspacesafely while refusing symlinks and path escapes.
04 / Benchmarks
Measured Cold-Start Latency
Measured end-to-end through the MCP server (50 runs per backend on WSL2 Ubuntu with Docker Desktop).
| Backend | How it runs | Median | p95 |
|---|---|---|---|
native |
Linux kernel isolation (no Docker) | 118 ms | 141 ms |
container |
Throwaway Docker container | 895 ms | 1002 ms |
The container path here goes through Docker Desktop's VM, a hop a Docker Engine user on Linux doesn't pay, and each container run also starts one cleanup check (
docker ps). So these are this host's numbers, not a speed-up factor.
05 / Security
Honest Threat Model
Clear boundaries on what Vestibule protects — and what it doesn't. Every run ends with an honest isolation: verdict.
What holds
For a run reporting native or container isolation, short of a kernel or container-runtime bug:
- Host files stay private — files outside
/workspacedon't exist inside the sandbox. - No internet or network access — outbound connections are blocked at the kernel level.
- Resource caps enforced — memory (no swap), CPU, process count,
/tmpsize, and timeout. - Honest status every run — clearly reports full isolation, degraded limits, or
Blocked:.
What stays possible & what it isn't
Clear boundaries before trusting any sandbox with real credentials or projects:
- Not a VM. On Linux, the sandbox shares your host kernel, so a kernel bug could in principle escape it.
- Only
run_codeis sandboxed. Your agent's own shell and file tools still run on your machine unless you restrict them. /workspaceis writable (unless mounted read-only) and may contain symlinks created by code — Vestibule refuses symlinks, so keep it separate from real projects.- Output returns to your agent and is sent to its model provider.
- Untested environments: arm64 Linux, Podman, and container runs on macOS.