summaryrefslogtreecommitdiffstats
path: root/crypto/cms/cms_ess.c
diff options
context:
space:
mode:
authorShane Lontis <shane.lontis@oracle.com>2020-12-11 19:19:37 +1000
committerTomas Mraz <tomas@openssl.org>2021-01-18 15:01:26 +0100
commit84af8027c5f2132a9166673e7a47b0f31c7cfe1d (patch)
tree1bc2caf1cc20b6362811fc8daff01b60a93ba732 /crypto/cms/cms_ess.c
parent0d83b7b9036feea680ba45751df028ff5e86cd63 (diff)
CMS: Fix NULL access if d2i_CMS_bio() is not passed a CMS_ContentInfo**.
Fixes #13624 Reviewed-by: Tim Hudson <tjh@openssl.org> Reviewed-by: Tomas Mraz <tomas@openssl.org> (Merged from https://github.com/openssl/openssl/pull/13668)
Diffstat (limited to 'crypto/cms/cms_ess.c')
-rw-r--r--crypto/cms/cms_ess.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/crypto/cms/cms_ess.c b/crypto/cms/cms_ess.c
index ba05d4695c..9b02bb4363 100644
--- a/crypto/cms/cms_ess.c
+++ b/crypto/cms/cms_ess.c
@@ -219,8 +219,9 @@ static int cms_msgSigDigest(CMS_SignerInfo *si,
if (md == NULL)
return 0;
if (!asn1_item_digest_ex(ASN1_ITEM_rptr(CMS_Attributes_Verify), md,
- si->signedAttrs, dig, diglen, si->cms_ctx->libctx,
- si->cms_ctx->propq))
+ si->signedAttrs, dig, diglen,
+ cms_ctx_get0_libctx(si->cms_ctx),
+ cms_ctx_get0_propq(si->cms_ctx)))
return 0;
return 1;
}