{"id":"3e6b04b450a61eb5","repo":"redis/redis-py","slug":"delegate-not-authorized-for-ocsp-signing","errorCode":null,"errorMessage":"delegate not authorized for ocsp signing","messagePattern":"delegate not authorized for ocsp signing","errorType":"exception","errorClass":"ConnectionError","httpStatus":null,"severity":"error","filePath":"redis/ocsp.py","lineNumber":101,"sourceCode":"        responder_name is not None\n        and responder_name == issuer_cert.subject\n        or responder_hash == issuer_hash\n    ):\n        cert_to_validate = issuer_cert\n    else:\n        certs = ocsp_response.certificates\n        responder_certs = _get_certificates(\n            certs, issuer_cert, responder_name, responder_hash\n        )\n\n        try:\n            responder_cert = responder_certs[0]\n        except IndexError:\n            raise ConnectionError(\"no certificates found for the responder\")\n\n        ext = responder_cert.extensions.get_extension_for_class(x509.ExtendedKeyUsage)\n        if ext is None or x509.oid.ExtendedKeyUsageOID.OCSP_SIGNING not in ext.value:\n            raise ConnectionError(\"delegate not authorized for ocsp signing\")\n        cert_to_validate = responder_cert\n\n    if validate:\n        _verify_response(cert_to_validate, ocsp_response)\n    return True\n\n\ndef _get_certificates(certs, issuer_cert, responder_name, responder_hash):\n    if responder_name is None:\n        certificates = [\n            c\n            for c in certs\n            if _get_pubkey_hash(c) == responder_hash and c.issuer == issuer_cert.subject\n        ]\n    else:\n        certificates = [\n            c\n            for c in certs","sourceCodeStart":83,"sourceCodeEnd":119,"githubUrl":"https://github.com/redis/redis-py/blob/da03cdc7e8731092b13e395605c3c1fb2de25de1/redis/ocsp.py#L83-L119","documentation":"Error \"delegate not authorized for ocsp signing\" thrown in redis/redis-py.","triggerScenarios":"Thrown at redis/ocsp.py:101 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"analyzedSha":"da03cdc7e8731092b13e395605c3c1fb2de25de1","analyzedAt":"2026-08-04T20:26:47.563Z","schemaVersion":2}