At OpenAI, we take a defense-in-depth approach to agent security. Our investments in training and alignment are the foundation of that work; at the same time, we have implemented related functionality in the agent harness Codex to provide additional protection. Running commands on your computer is one of the most common things Codex does, and it can be risky. So we built the Codex sandbox to let Codex work in your existing environment while honoring the filesystem and network restrictions you control.
[5][6][8]A sandbox limits the resources a program can access while it runs. For a photo-organizing task, you could configure the Codex sandbox to let commands read and modify files in ~/Pictures while blocking network access to prevent uploads. For a code review, you could allow access to online documentation while keeping source files read-only. Users configure the Codex sandbox through permission profiles, which define the filesystem and network restrictions for a Codex session.