mirror of
https://github.com/openai/codex.git
synced 2026-11-29 00:00:54 +00:00
## Why Read-restricted sandboxes build a synthetic filesystem around paths granted by policy. Leaving the backing mounts writable lets commands modify synthetic directories outside explicitly writable paths. ## What changed Remount the synthetic root, minimal `/dev`, and applicable WSL masks read-only after bubblewrap finishes setting up mounts. The remounts are nonrecursive, so explicitly writable child mounts stay writable. ## Testing Extend the sandbox regression test to check that commands can read an approved file through a symlink, write to `/dev/null`, and write to an allowed subdirectory under a denied parent. The test also checks that commands cannot rename the synthetic directory containing the approved file or create an ungranted directory under `/dev`. GitOrigin-RevId: e2ddc6c4a215d052adf12e2644480a2eb9c72640