Inside the Codex Sandbox
OpenAI, Wednesday, November 18th, 2026
OpenAI explains how the Codex sandbox limits filesystem and network access for agent commands on macOS, Linux and Windows.
Codex runs commands in the user's existing environment rather than a VM or container, using OS sandboxing to enforce permission profiles that set filesystem and network limits.
The default workspace profile allows writes in the workspace, keeps .git and .codex read-only, allows broad reads and disables network access.
Users and enterprises can define layered profiles, restrict network access to allowed domains through a proxy, and use the codex sandbox command to wrap other tools such as MCP servers.
The post covers Seatbelt on macOS, bubblewrap with seccomp on Linux, and a move to Microsoft's MXC on Windows.