[linux sandbox] Isolate IPC namespace in bubblewrap#20240
[linux sandbox] Isolate IPC namespace in bubblewrap#20240evawong-oai wants to merge 1 commit intomainfrom
Conversation
|
@codex review |
|
Codex Review: Didn't find any major issues. Chef's kiss. ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
…+20240 - anomalyco/opencode#24984 fix(core): reconnect editor context for session directory (merge-after-nits) - openai/codex#20243 Add codex-core public API listing (merge-as-is) - openai/codex#20240 [linux sandbox] Isolate IPC namespace in bubblewrap (merge-as-is)
9163360 to
eec6cc3
Compare
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
codex/codex-rs/sandboxing/src/manager.rs
Lines 317 to 318 in eec6cc3
Update the WSL1 gate to consider memory IPC isolation. select_initial can now pick LinuxSeccomp for managed full-access profiles, and linux_run_main will invoke bwrap when memory_profile.should_unshare_ipc() is true. But this check still treats unrestricted/no-proxy as “no bwrap required”, so WSL1 paths pass validation and then fail later at runtime with unsupported bwrap behavior.
codex/codex-rs/linux-sandbox/src/linux_run_main.rs
Lines 268 to 270 in eec6cc3
Block --use-legacy-landlock when memory isolation is required. This guard only checks direct-runtime filesystem enforcement, so managed unrestricted profiles (now defaulting to isolate_ipc=true) are allowed in legacy mode, which skips bubblewrap and never adds --unshare-ipc, leaving host IPC shared contrary to the new default.
codex/codex-rs/tools/src/tool_config.rs
Line 365 in eec6cc3
Include memory-based sandbox requirements in this predicate. After this change, managed unrestricted+network-enabled profiles still require platform sandbox (for IPC isolation), but this check treats them as sandbox-free and keeps UnifiedExec enabled on Windows. That bypasses the intended fallback path for sandbox-required managed sessions and can route commands through an incompatible backend.
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
612c06f to
cfe2e46
Compare
|
Addressing the Codex review above.
|
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: cfe2e46620
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
cfe2e46 to
c3ff56b
Compare
Why
Summary
--unshare-ipcto the Linux bubblewrap argv when bubblewrap is active./dev/shmworkflow validated.Validation
evawong-pr-validation: 13 passed, 0 failed, 1 skipped./home/dev-user/codex-bugb16097-pr-validation/logs/20260430T222251Z-pr20240-codex-comments-main.log.just fmt.git diff --check.:workspacepermissions profile. This is separate from System V IPC namespace isolation.Tickets