{"record":{"id":"03bd7cee14c73ea7","repo":"openai/codex","slug":"failed-to-verify-descriptor-backed-bubblewrap-moun","errorCode":null,"errorMessage":"failed to verify descriptor-backed bubblewrap mount: {err}","messagePattern":"failed to verify descriptor-backed bubblewrap mount: (.+?)","errorType":"panic","errorClass":null,"httpStatus":null,"severity":"error","filePath":"codex-rs/linux-sandbox/src/linux_run_main.rs","lineNumber":196,"sourceCode":"    }\n    ensure_inner_stage_mode_is_valid(apply_seccomp_then_exec, use_legacy_landlock);\n    let EffectivePermissions {\n        permission_profile,\n        mut file_system_sandbox_policy,\n        network_sandbox_policy,\n    } = resolve_permission_profile(permission_profile).unwrap_or_else(|err| panic!(\"{err}\"));\n    ensure_legacy_landlock_mode_supports_policy(\n        use_legacy_landlock,\n        &file_system_sandbox_policy,\n        network_sandbox_policy,\n        &sandbox_policy_cwd,\n    );\n\n    // Inner stage: apply seccomp/no_new_privs after bubblewrap has already\n    // established the filesystem view.\n    if apply_seccomp_then_exec {\n        if let Err(err) = crate::fd_mount::verify_fd_mounts(&verify_fd_mounts) {\n            panic!(\"failed to verify descriptor-backed bubblewrap mount: {err}\");\n        }\n\n        let mut capability_header = [LINUX_CAPABILITY_VERSION_3, 0];\n        let mut capability_sets = [[0_u32; 3]; 2];\n        // SAFETY: capability ABI version 3 uses a [version, pid] header and\n        // two [effective, permitted, inheritable] capability-set entries.\n        let result = unsafe {\n            libc::syscall(\n                libc::SYS_capget,\n                capability_header.as_mut_ptr(),\n                capability_sets.as_mut_ptr(),\n            )\n        };\n        if result < 0 {\n            panic!(\n                \"failed to verify Linux sandbox capabilities: {}\",\n                std::io::Error::last_os_error()\n            );","sourceCodeStart":178,"sourceCodeEnd":214,"githubUrl":"https://github.com/openai/codex/blob/339751715c64496cb86246bfb3935f40e309dd3d/codex-rs/linux-sandbox/src/linux_run_main.rs#L178-L214","documentation":"During the inner sandbox stage, one of the descriptor-backed bubblewrap mounts failed verification. This panic in run_main fires when verify_fd_mounts rejects the fds passed via --verify-fd-mount, meaning an expected bind mount was not correctly established by the outer bwrap stage — a sandbox-integrity violation that must abort rather than run the command under incorrect isolation.","triggerScenarios":"Thrown at codex-rs/linux-sandbox/src/linux_run_main.rs:196 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Inspect the inner io::Error to see which fd/mount failed verification","Check that the outer bwrap stage passes the matching --ro-bind-fd arguments for every verified fd","Verify the system bubblewrap supports fd-based binds (run `bwrap --help` and look for --ro-bind-fd)","Report as a bug if the mount list appears consistent"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"339751715c64496cb86246bfb3935f40e309dd3d","analyzedAt":"2026-08-25T05:35:09.876Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}