openai/codex · error

error activating Linux proxy routing bridge

Error message

error activating Linux proxy routing bridge: {err}

What it means

Activating the managed proxy routing bridge inside the sandbox network namespace failed. This panic in run_main fires when activate_proxy_routes_in_netns rejects the parsed --proxy-route-spec — typically because loopback endpoints are missing, unparseable, or do not match the planned routes — so the sandboxed command could not be given its proxied network view.

Solutions

  1. Inspect the inner error in the message for the exact routing failure
  2. Verify the proxy route spec endpoints are live loopback listeners before launch
  3. Ensure the host-side proxy bridge is started before the sandboxed command
  4. Regenerate the route spec from the current proxy configuration
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at codex-rs/linux-sandbox/src/linux_run_main.rs:228 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/bf4a089959d80c2f. Report an issue: GitHub.

Appendix: source

Thrown at codex-rs/linux-sandbox/src/linux_run_main.rs:228

        if result < 0 {
            panic!(
                "failed to verify Linux sandbox capabilities: {}",
                std::io::Error::last_os_error()
            );
        }
        if capability_sets
            .into_iter()
            .any(|[effective, permitted, _]| effective != 0 || permitted != 0)
        {
            panic!("Linux sandbox retained effective or permitted capabilities");
        }

        if allow_network_for_proxy {
            let spec = proxy_route_spec
                .as_deref()
                .unwrap_or_else(|| panic!("managed proxy mode requires --proxy-route-spec"));
            if let Err(err) = activate_proxy_routes_in_netns(spec) {
                panic!("error activating Linux proxy routing bridge: {err}");
            }
        }
        let proxy_routing_active = allow_network_for_proxy;
        if let Err(e) = apply_permission_profile_to_current_thread(
            &permission_profile,
            &sandbox_policy_cwd,
            /*apply_landlock_fs*/ false,
            allow_network_for_proxy,
            proxy_routing_active,
        ) {
            panic!("error applying Linux sandbox restrictions: {e:?}");
        }

        let signal_mask = ForwardedSignalMask::block();
        let command_pid = unsafe { libc::fork() };
        if command_pid < 0 {
            let err = std::io::Error::last_os_error();
            panic!("failed to fork sandboxed command: {err}");

View on GitHub (pinned to 339751715c)