{"record":{"id":"a75952c0b91953b0","repo":"openai/codex","slug":"network-proxy-route-does-not-enable-socks5","errorCode":null,"errorMessage":"network proxy route does not enable SOCKS5","messagePattern":"network proxy route does not enable SOCKS5","errorType":"exception","errorClass":"io::Error","httpStatus":null,"severity":"error","filePath":"codex-rs/network-proxy/src/windows_proxy_ingress.rs","lineNumber":75,"sourceCode":"impl Service<TcpStream> for IngressDispatcher {\n    type Output = ();\n    type Error = BoxError;\n\n    async fn serve(&self, stream: TcpStream) -> Result<(), BoxError> {\n        let local_addr = stream.local_addr()?;\n        let peer_addr = stream.peer_addr()?;\n        let restricting_sids = restricting_sids_for_tcp_connection(local_addr, peer_addr)?;\n        let route = {\n            let routes = self\n                .routes\n                .lock()\n                .unwrap_or_else(std::sync::PoisonError::into_inner);\n            registered_route_for_sids(&routes, &restricting_sids)?\n        };\n        let service = match self.protocol {\n            ProxyProtocol::Http => route.http.clone(),\n            ProxyProtocol::Socks => route.socks.clone().ok_or_else(|| {\n                io::Error::new(\n                    io::ErrorKind::PermissionDenied,\n                    \"network proxy route does not enable SOCKS5\",\n                )\n            })?,\n        };\n        service.serve(stream).await\n    }\n}\n\npub(crate) struct WindowsProxyIngress {\n    http_addr: SocketAddr,\n    routes: RouteRegistry,\n    runtime: Handle,\n    http_task: JoinHandle<()>,\n    socks: Mutex<SocksListenerState>,\n}\n\nstruct SocksListenerState {","sourceCodeStart":57,"sourceCodeEnd":93,"githubUrl":"https://github.com/openai/codex/blob/339751715c64496cb86246bfb3935f40e309dd3d/codex-rs/network-proxy/src/windows_proxy_ingress.rs#L57-L93","documentation":"Windows ingress guard in IngressDispatcher::serve: a client connection was attributed to a route whose registered services do not enable SOCKS5, so the shared ingress cannot dispatch the stream to a SOCKS handler. The connection is refused because the matched route only supports protocols it has not enabled.","triggerScenarios":"Thrown at codex-rs/network-proxy/src/windows_proxy_ingress.rs:75 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Enable SOCKS5 on the network proxy route the client connects through","Connect via the route's enabled protocol (e.g. HTTP proxy) instead"],"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"}