diff options
Diffstat (limited to 'src/lib/libcrypto/cms/cms_smime.c')
-rw-r--r-- | src/lib/libcrypto/cms/cms_smime.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/lib/libcrypto/cms/cms_smime.c b/src/lib/libcrypto/cms/cms_smime.c index d39ee19aa5..367810f40e 100644 --- a/src/lib/libcrypto/cms/cms_smime.c +++ b/src/lib/libcrypto/cms/cms_smime.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: cms_smime.c,v 1.23 2019/08/11 14:51:15 jsing Exp $ */ | 1 | /* $OpenBSD: cms_smime.c,v 1.24 2019/10/04 18:03:56 tb Exp $ */ |
2 | /* | 2 | /* |
3 | * Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL | 3 | * Written by Dr Stephen N Henson (steve@openssl.org) for the OpenSSL |
4 | * project. | 4 | * project. |
@@ -823,6 +823,10 @@ CMS_decrypt(CMS_ContentInfo *cms, EVP_PKEY *pk, X509 *cert, BIO *dcont, | |||
823 | cms->d.envelopedData->encryptedContentInfo->debug = 1; | 823 | cms->d.envelopedData->encryptedContentInfo->debug = 1; |
824 | else | 824 | else |
825 | cms->d.envelopedData->encryptedContentInfo->debug = 0; | 825 | cms->d.envelopedData->encryptedContentInfo->debug = 0; |
826 | if (!cert) | ||
827 | cms->d.envelopedData->encryptedContentInfo->havenocert = 1; | ||
828 | else | ||
829 | cms->d.envelopedData->encryptedContentInfo->havenocert = 0; | ||
826 | if (!pk && !cert && !dcont && !out) | 830 | if (!pk && !cert && !dcont && !out) |
827 | return 1; | 831 | return 1; |
828 | if (pk && !CMS_decrypt_set1_pkey(cms, pk, cert)) | 832 | if (pk && !CMS_decrypt_set1_pkey(cms, pk, cert)) |