summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authortb <>2025-09-30 12:49:34 +0000
committertb <>2025-09-30 12:49:34 +0000
commit4867be3b7736b15337f62460c0a92c9f3f6f5005 (patch)
tree5a4e775e781f842f12ef2eb4d065e8427e285016 /src/lib
parent9c492217dca486db9aacff39780c63445db043a4 (diff)
downloadopenbsd-4867be3b7736b15337f62460c0a92c9f3f6f5005.tar.gz
openbsd-4867be3b7736b15337f62460c0a92c9f3f6f5005.tar.bz2
openbsd-4867be3b7736b15337f62460c0a92c9f3f6f5005.zip
cms_RecipientInfo_pwri_crypt: fix incorrect return check
ok jsing
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/libcrypto/cms/cms_pwri.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lib/libcrypto/cms/cms_pwri.c b/src/lib/libcrypto/cms/cms_pwri.c
index 298c67a5f4..99def8a215 100644
--- a/src/lib/libcrypto/cms/cms_pwri.c
+++ b/src/lib/libcrypto/cms/cms_pwri.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: cms_pwri.c,v 1.33 2025/09/30 12:46:55 tb Exp $ */ 1/* $OpenBSD: cms_pwri.c,v 1.34 2025/09/30 12:49:34 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.
@@ -389,8 +389,8 @@ cms_RecipientInfo_pwri_crypt(CMS_ContentInfo *cms, CMS_RecipientInfo *ri,
389 389
390 /* Finish password based key derivation to setup key in "ctx" */ 390 /* Finish password based key derivation to setup key in "ctx" */
391 391
392 if (EVP_PBE_CipherInit(algtmp->algorithm, (char *)pwri->pass, 392 if (!EVP_PBE_CipherInit(algtmp->algorithm, (char *)pwri->pass,
393 pwri->passlen, algtmp->parameter, kekctx, en_de) < 0) { 393 pwri->passlen, algtmp->parameter, kekctx, en_de)) {
394 CMSerror(ERR_R_EVP_LIB); 394 CMSerror(ERR_R_EVP_LIB);
395 goto err; 395 goto err;
396 } 396 }