[openssl/openssl] e70c79: crypto/evp: fix double free of tmp_keymgmt in sig/...

"'Dexter.k' via openssl-commits" <[email protected]>
Newsgroups gmane.comp.encryption.openssl.cvs
Message-ID <openssl/openssl/push/refs/heads/openssl-3.4/[email protected]>
  Branch: refs/heads/openssl-3.4
  Home:   https://github.com/openssl/openssl
  Commit: e70c79415c0a49b700158e8f4307ea55bb50a8bd
      https://github.com/openssl/openssl/commit/e70c79415c0a49b700158e8f4307ea55bb50a8bd
  Author: rootvector2 <[email protected]>
  Date:   2026-05-31 (Sun, 31 May 2026)

  Changed paths:
    M crypto/evp/asymcipher.c
    M crypto/evp/kem.c
    M crypto/evp/signature.c

  Log Message:
  -----------
  crypto/evp: fix double free of tmp_keymgmt in sig/kem/asym init

Commit ecb4757b377f "crypto/evp/m_sigver.c: fix potential double free
on error path in do_sigver_init" has fixed double-free of tmp_keymgmt
in do_sigver_init() by setting it to NULL after EVP_KEYMGMT_free() call;
the same issue present in evp_kem_init(), evp_pkey_asym_cipher_init(),
and evp_pkey_signature_init().  Address it similarly, by setting
the pointers to NULL after *_free() calls.

Complements: ecb4757b377f "crypto/evp/m_sigver.c: fix potential double free on error path in do_sigver_init"
Fixes: 839ffdd11cd4 "EVP: Allow a fallback for operations that work with an EVP_PKEY"
CLA: trivial

Reviewed-by: Kurt Roeckx <[email protected]>
Reviewed-by: Tomas Mraz <[email protected]>
Reviewed-by: Eugene Syromiatnikov <[email protected]>
MergeDate: Sun May 31 11:03:15 2026
(Merged from https://github.com/openssl/openssl/pull/31312)

(cherry picked from commit a21f77dbc99c242b73b5b420714a2cd36bee084a)



To unsubscribe from these emails, change your notification settings at https://github.com/openssl/openssl/settings/notifications

-- 
You received this message because you are subscribed to the Google Groups "openssl-commits" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To view this discussion visit https://groups.google.com/a/openssl.org/d/msgid/openssl-commits/openssl/openssl/push/refs/heads/openssl-3.4/50e0c6-e70c79%40github.com.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.