]> git.ipfire.org Git - thirdparty/openssl.git/commitdiff
Update cms_pwri.c
authorKenzlee51 <121612281+Kenzlee51@users.noreply.github.com>
Tue, 8 Apr 2025 10:56:50 +0000 (13:56 +0300)
committerMatt Caswell <matt@openssl.org>
Tue, 15 Apr 2025 14:42:50 +0000 (15:42 +0100)
CLA: trivial

When entering the branch (pbe_nid <= 0), line 66 assigns new values ​​to the variable of line 67 (pbe_nid = NID_id_pbkdf2).
However, it is not used anywhere in the future.
For this reason, lines 66 and 67 were removed.

Reviewed-by: Saša Nedvědický <sashan@openssl.org>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Matt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/27296)

crypto/cms/cms_pwri.c

index a7d609f83791a21ed5b3fe3ff1c87659e78bbdef..d907ad9a57ae465dff1204453a03965ea3a1a9a7 100644 (file)
@@ -63,9 +63,6 @@ CMS_RecipientInfo *CMS_add0_recipient_password(CMS_ContentInfo *cms,
     if (wrap_nid <= 0)
         wrap_nid = NID_id_alg_PWRI_KEK;
 
-    if (pbe_nid <= 0)
-        pbe_nid = NID_id_pbkdf2;
-
     /* Get from enveloped data */
     if (kekciph == NULL)
         kekciph = ec->cipher;