Isolation
This page is a recommendation, not a mechanism. The template builds no sandbox and adds no file to your project for this. It points to the switches the tools themselves offer. Those tools change often, so every statement below carries the date it was checked (checked 2026-11-06) and a link to the vendor’s page instead of a copied list. Read the source before you rely on a setting.
Limits first
Section titled “Limits first”- The template’s checks are guard rails against mistakes, not a sandbox. They catch a careless read or write; they do not hold back an agent, or text injected into its prompt, that is set on getting around them. They refuse only what the command shows: inline code whose write target its text does not show passes, a shown
.act/path is still refused, and a read of a path that does not exist passesoutside-root. - Claude Code’s sandbox covers shell commands only. Per Anthropic’s sandboxing page, Read, Edit, Write, WebFetch and WebSearch are governed by permission rules alone: a
denyReadentry does not stop the Read tool, andallowedDomainsdoes not limit WebFetch. Command hooks, local MCP servers, LSP servers, the status line andapiKeyHelperalso run outside it. Isolating the whole process takes the sandbox runtime, a container or a VM (overview). - The sandbox is off by default, and by default shell commands can read most of the machine,
~/.sshand~/.aws/credentialsincluded, unless you deny it. If the platform or its dependencies are missing, Claude Code runs unsandboxed without stopping, unlesssandbox.failIfUnavailableistrue. - Native Windows: Claude Code has no sandbox there and runs commands unsandboxed. Anthropic names a container, a VM, or the Bash sandbox inside WSL2. Of the tools below, only Claude Code and Cursor lack a native Windows sandbox; Cursor runs its Linux sandbox inside WSL2.
- Local models: Anthropic documents
ANTHROPIC_BASE_URLfor gateways but does not support routing Claude Code to non-Claude models through any gateway (source). A fully local level therefore needs another tool. Which tools run local models was not verified. - Isolation does not change what is sent to the model, and any network target you allow can still receive what the agent has read.
Three levels
Section titled “Three levels”| Level | Model | Network | Where it runs |
|---|---|---|---|
| Standard | cloud | open | your developer machine |
| Isolated | cloud | only to allowed targets | sandbox, container or VM |
| Local | local | none | a machine with no internet |
Standard
Section titled “Standard”The default: the tool’s normal permission prompts, plus the template’s checks below. Switching on the tool’s own sandbox for shell commands is a cheap first step. Only the Claude Code sandbox is enforced by Claude Code itself; a committed dev container is a convention, not an enforcement boundary (source).
Isolated
Section titled “Isolated”Cloud model, network limited to targets you name. The switch per tool, all checked 2026-11-06:
| Tool | Switch | Source |
|---|---|---|
| Claude Code | /sandbox or sandbox.enabled, domains in sandbox.network.allowedDomains (shell commands only, WebFetch and MCP are not limited); a command can retry unsandboxed via dangerouslyDisableSandbox, closed with sandbox.allowUnsandboxedCommands: false; for the whole process the reference dev container with its firewall script, the sandbox runtime (beta research preview), a container or a VM. Always run --dangerously-skip-permissions sessions inside a container, a VM or the sandbox runtime. |
sandboxing, environments, dev container |
| OpenAI Codex CLI | sandbox_mode (read-only, workspace-write, danger-full-access); network is off by default and is enabled in the sandbox settings; domain rules are a beta profile. Whether MCP servers run sandboxed: not verified. |
security, sandboxing |
| Gemini CLI | opt-in: --sandbox, GEMINI_SANDBOX or tools.sandbox; backends include Seatbelt, Docker, Podman, gVisor and Windows native. Whether the sandbox is on by default with --yolo: not verified, read the configuration page. |
sandbox, configuration |
| GitHub Copilot | cloud agent: a firewall, on by default, with a custom allowlist in the repository settings; it covers the agent’s Bash tool, not MCP servers or setup steps. CLI: local sandbox, off by default (/sandbox enable); outbound internet is on by default there. A domain allowlist for the CLI: not verified. |
firewall, local sandboxing |
| Cursor | sandbox for terminal commands, network denied by default and set in sandbox.json. Whether file edits and MCP are sandboxed: not verified. The default Auto-review mode is, in Cursor’s words, not a security boundary. |
run modes, sandbox |
A dev container is only as tight as its settings. Anthropic warns that with --dangerously-skip-permissions the reference container does not stop a malicious project from exfiltrating what is inside it, including the credentials in ~/.claude; use it for trusted repositories only and do not mount ~/.ssh or cloud credentials. Workspace edits reach the host through the bind mount.
No internet, local model. Claude Code is not an option here (see the limits). The pages above were not checked for local-model support, so this level is not verified for every tool; check the tool’s own documentation for a local provider, and cut the machine off from the network yourself, for instance with a firewall or a network-less container.
What the template’s checks add
Section titled “What the template’s checks add”secret-read, outside-root, git-metadata-guard and the worker’s write scope work inside the session, in Claude Code only (the other tools have no hooks, Gemini CLI gets only the skills; see the introduction): they refuse a read of a secret file, a read or write outside the project and its allowed places, a write to git hooks and repository config, and a worker’s write outside its assignment (.act-local/tmp/ is open to every worker). outside-root and secret-read also check the paths that the IDE server’s known read tools take. A place outside the project is allowed only as an outside-root-allow entry; an absolute entry outside the project and home (a browser or SDK folder) is read-only, and a file: entry is ignored. A file that looks like a secret but may be read goes into secret-read-allow, a row only you write; a package cannot set it. template-write-guard also refuses writes to .act-local/packages/ and moving, renaming or removing .act-local as a whole; a plain copy into it passes this guard. protected-watch adds a check after the fact: after every tool call it compares the files that R-safe-git-metadata protects (git hooks, the keys of .git/config that start code, Claude settings, agents and skills, .mcp.json, .envrc, dev container and editor tasks) with a snapshot from session start, whichever way they changed, a script file included. A change a worker made is put back and kept under .act-local/protected-watch/kept/; one the orchestrator made is only reported. It prevents nothing, since it reports after the call (Checks). They are guard rails against mistakes; none of them replaces a level’s isolation, and their limits are in Configuration and the rules they belong to.