{"record":{"id":"44844b3bc54e605f","repo":"openai/codex","slug":"failed-to-register-certificate-certificate-index","errorCode":null,"errorMessage":"Failed to register certificate #{certificate_index} from {} selected by {} in rustls root store: {source}. {hint}","messagePattern":"Failed to register certificate #(.+?) from (.+?) selected by (.+?) in rustls root store: (.+?)\\. (.+?)","errorType":"exception","errorClass":"BuildCustomCaTransportError","httpStatus":null,"severity":"error","filePath":"codex-rs/http-client/src/custom_ca.rs","lineNumber":133,"sourceCode":"    /// Reqwest rejected the final client configuration after a custom CA bundle was loaded.\n    #[error(\n        \"Failed to build HTTP client while using CA bundle from {} ({}): {source}\",\n        source_env,\n        path.display()\n    )]\n    BuildClientWithCustomCa {\n        source_env: &'static str,\n        path: PathBuf,\n        #[source]\n        source: reqwest::Error,\n    },\n\n    /// Reqwest rejected the final client configuration while using only system roots.\n    #[error(\"Failed to build HTTP client while using system root certificates: {0}\")]\n    BuildClientWithSystemRoots(#[source] reqwest::Error),\n\n    /// One parsed certificate block could not be registered with the websocket TLS root store.\n    #[error(\n        \"Failed to register certificate #{certificate_index} from {} selected by {} in rustls root store: {source}. {hint}\",\n        path.display(),\n        source_env,\n        hint = CA_CERT_HINT\n    )]\n    RegisterRustlsCertificate {\n        source_env: &'static str,\n        path: PathBuf,\n        certificate_index: usize,\n        source: rustls::Error,\n    },\n}\n\nimpl From<BuildCustomCaTransportError> for io::Error {\n    fn from(error: BuildCustomCaTransportError) -> Self {\n        match error {\n            BuildCustomCaTransportError::ReadCaFile { ref source, .. } => {\n                io::Error::new(source.kind(), error)","sourceCodeStart":115,"sourceCodeEnd":151,"githubUrl":"https://github.com/openai/codex/blob/339751715c64496cb86246bfb3935f40e309dd3d/codex-rs/http-client/src/custom_ca.rs#L115-L151","documentation":"Error \"Failed to register certificate #{certificate_index} from {} selected by {} in rustls root store: {source}. {hint}\" thrown in openai/codex.","triggerScenarios":"Thrown at codex-rs/http-client/src/custom_ca.rs:133 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"339751715c64496cb86246bfb3935f40e309dd3d","analyzedAt":"2026-08-25T05:35:09.876Z","schemaVersion":2},"datasetVersion":"2026-08-25T06:17:31.827Z"}