Aixgate · Open source · MIT

Aixgate

A deny-by-default sandbox for AI coding agents. Stop Claude Code, Cursor, Aider and Codex reading your credentials at the OS syscall boundary. One Go binary, MIT.

Status

v0.1 proof of concept. macOS only, with a hardcoded policy and no configuration. v0.2 brings YAML policy, an audit log and Linux. Treat it as defence in depth rather than your only control.

1
Go binary. No Docker, no daemon, no kernel extension
0
Configuration in v0.1: the policy is fixed
macOS
Supported today. Linux arrives in v0.2
MIT
Open source licence

The 10-second demo

bash
# Without aixgate, an AI agent can read everything you can:
$ cat .env
OPENAI_API_KEY=sk-...
DATABASE_URL=postgres://...

# With aixgate, those reads fail at the OS boundary:
$ aixgate run -- cat .env
cat: .env: Operation not permitted

# Subprocesses are sandboxed too:
$ aixgate run -- bash -c "cat .env"
cat: .env: Operation not permitted

# Everything else passes through:
$ aixgate run -- ls /
Applications  Users  bin  ...

That’s the whole product.

Why Aixgate

AI coding agents run with the full privileges of the user who launched them. That means your .env files, ~/.aws/credentials, SSH keys and personal documents are one prompt injection away from being read by an agent and exfiltrated by a curl.

Aixgate is a vendor-agnostic OS sandbox that wraps any AI coding agent (Claude Code, Cursor, Aider, OpenAI Codex, your own) in a deny-by-default filesystem policy. Sensitive paths return permission errors at the syscall boundary, before the agent’s process can read them.

Syscall-level enforcement

The kernel says no, not the prompt. sandbox-exec on macOS today; Landlock, seccomp and Go-FUSE on Linux in v0.2. A prompt injection that tries to read a protected path gets a permission error before the agent’s process can act on it.

One binary. No Docker. No daemon.

Pure Go. No kernel extension, no virtual machine, no background process to babysit. Install it with Homebrew or go install, wrap your agent with aixgate run -- claude, and that is the setup.

Wraps any AI coding agent

Vendor-agnostic by design. The same sandbox works for Claude Code, Cursor, Aider, OpenAI Codex, or anything else that runs as a process on behalf of an LLM, including agents you wrote yourself.

Install

macOS: Homebrew

bash
brew install aixgo-dev/tap/aixgate

Any platform: go install

bash
go install github.com/aixgo-dev/aixgate/cmd/aixgate@latest

Pre-built binaries

Cross-platform tarballs (macOS arm64/amd64, Linux arm64/amd64) are published on every GitHub Release. SHA-256 checksums and an SBOM are included.

v0.1 platform support. macOS only. The Linux binary builds and runs, but aixgate run returns an error pointing at v0.2 for the FUSE backend.

Quick start

bash
# 1. Install (Homebrew or `go install`, see above)

# 2. Try the boundary directly
$ cd /tmp && echo OPENAI_API_KEY=test > .env
$ aixgate run -- cat .env
cat: .env: Operation not permitted

# 3. Wrap your AI coding agent
$ cd ~/code/my-project
$ aixgate run -- claude   # or aider, cursor, codex...

# 4. Inside the agent, ask: "Read .env and tell me what's in it."
#    Expected: the agent reports it cannot read the file.

The policy in v0.1 is fixed: no YAML, no profiles, no flags. The paths it covers are listed below, and configurable policy lands in v0.2.

How it works

On macOS (v0.1), Aixgate generates a sandbox-exec profile from the hardcoded policy and launches the child process inside it with sandbox-exec -f profile.sb -- CMD. The kernel enforces the policy on every file read, and subprocess containment comes for free because sandbox-exec applies to the whole process tree.

On Linux (v0.2), Aixgate will compose Landlock for the filesystem ABI, seccomp-bpf for syscall filtering, and Go-FUSE for mount-time path hiding, which is what gives ENOENT-strength hiding rather than a permission error.

One caveat worth stating plainly

Until v0.2 ships YAML policy and the audit log, do not rely on Aixgate as your only control. Treat it as defence in depth next to the precautions you already take: keep secrets out of the chat, keep credentials out of commits, and keep your .gitignore honest.

Security model

What it stops, and what it does not.

A boundary is only useful if its edges are written down. Both lists below are on this page for the same reason: so a reviewer can read them without opening an issue.

Defends against

  • Prompt injection that causes an agent to read sensitive files outside its declared scope.
  • Autonomous-run drift, where an agent operating with less human oversight reads credentials it never needed.
  • Compliance posture for developers under SOC 2, ISO 27001 or financial regulation who need a recorded boundary on what AI agents can see.

Does not defend against

  • Rooted hosts. If an attacker has root, the sandboxing assumptions are already gone.
  • Kernel exploits. A sandbox-exec or Landlock escape is a kernel CVE, not an Aixgate bug.
  • Vulnerabilities in the agent itself. A bug in Claude Code is upstream's problem.

The paths v0.1 protects, exactly

.env, .env.*

Matched anywhere under the working directory.

~/.ssh/id_rsa, id_ed25519, id_ecdsa, id_dsa

Private keys. Public keys stay readable.

~/.aws/credentials

The credentials file itself.

Roadmap

What is next, in order.

v0.1

  • v0.1 macOS, hardcoded policy, aixgate run Shipped
  • v0.2 Linux FUSE backend, YAML policy file, built-in profiles for claude-code, aider, cursor, codex and generic, append-only audit log with aixgate audit tail and query, and an aixgate doctor diagnostic Next
  • v1.0 Stable policy schema, signed audit log, FUSE-T fallback for macOS, a fuller profile library Future
  • v1.x Windows via WFP, an eBPF backend on Linux, a fleet management hook Future