Landlock: fallback to supported ABI or exit with error
What version of Codex is running?
codex-cli 0.58.0
What subscription do you have?
API
Which model were you using?
gpt-5.1-codex
What platform is your computer?
Linux 6.1.0-41-amd64 x86_64 unknown
What issue are you seeing?
ABI::V5 is hardcoded under: https://github.com/openai/codex/blob/main/codex-rs/linux-sandbox/src/landlock.rs#L60
This effectively disables sandboxing for any Linux distribution with a kernel version below 6.12, like Debian 12 or Ubuntu 24.04, which are still supported and widely deployed. In my case, codex is able to freely access the filesystem, only restrained by the current user's permissions. I think this is inherently an insecure design since there was no warning whatsoever which informed me about this.
What steps can reproduce the bug?
Use a kernel below 6.12 and run codex sandbox linux ls .. as a minimal PoC.
Or simply ask codex in a normal session to read a file outside of the current directory, with default security settings.
What is the expected behavior?
If any enabled sandboxing feature is not working, codex should exit with an error after startup. Only if the user passes the argument --yolo or adjusts the sandbox in a way that would make it compatible, should codex run. There should be a --best-effort mode, similar to how landrun allows for it.
Additional information
_No response_
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗