openai/codex · error
error applying legacy Linux sandbox restrictions: {e:?}
Error message
error applying legacy Linux sandbox restrictions: {e:?} What it means
Error "error applying legacy Linux sandbox restrictions: {e:?}" thrown in openai/codex.
Source
Thrown at codex-rs/linux-sandbox/src/linux_run_main.rs:332
&sandbox_policy_cwd,
command_cwd.as_deref(),
&file_system_sandbox_policy,
network_sandbox_policy,
inner,
!no_proc,
allow_network_for_proxy,
);
}
// Legacy path: Landlock enforcement only, when bwrap sandboxing is not enabled.
if let Err(e) = apply_permission_profile_to_current_thread(
&permission_profile,
&sandbox_policy_cwd,
/*apply_landlock_fs*/ true,
allow_network_for_proxy,
/*proxy_routed_network*/ false,
) {
panic!("error applying legacy Linux sandbox restrictions: {e:?}");
}
exec_or_panic(command);
}
#[derive(Debug, Clone)]
struct EffectivePermissions {
permission_profile: PermissionProfile,
file_system_sandbox_policy: FileSystemSandboxPolicy,
network_sandbox_policy: NetworkSandboxPolicy,
}
#[derive(Debug, PartialEq, Eq)]
enum ResolvePermissionProfileError {
MissingConfiguration,
}
impl fmt::Display for ResolvePermissionProfileError {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {View on GitHub (pinned to 339751715c)
When it happens
Trigger: Thrown at codex-rs/linux-sandbox/src/linux_run_main.rs:332 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of openai/codex@339751715c (2026-08-25).
Data as JSON: /api/errors/f2fdcdcedb6996d3.
Report an issue: GitHub.