]> git.ipfire.org Git - thirdparty/openssl.git/commitdiff
apps/ocsp.c: Add missing test if make_ocsp_response failed
authorGW <gil.weisbord@gmail.com>
Sat, 12 Nov 2022 06:51:15 +0000 (08:51 +0200)
committerTomas Mraz <tomas@openssl.org>
Tue, 15 Nov 2022 10:59:30 +0000 (11:59 +0100)
CLA: trivial

Reviewed-by: Dmitry Belyavskiy <beldmit@gmail.com>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/19660)

apps/ocsp.c

index 380c6b325f332c0329f650bee91111e19261ed47..fb09036e77ad6f9064582dfb3baaf231ac48e19a 100644 (file)
@@ -730,6 +730,8 @@ redo_accept:
         make_ocsp_response(bio_err, &resp, req, rdb, rca_cert, rsigner, rkey,
                            rsign_md, rsign_sigopts, rother, rflags, nmin, ndays,
                            badsig, resp_certid_md);
+        if (resp == NULL)
+            goto end;
         if (cbio != NULL)
             send_ocsp_response(cbio, resp);
     } else if (host != NULL) {