[openssl/openssl] 4cfae9: Fix a potential memory leak in apps/s_server.c

beshoux noreply at github.com
Wed Feb 8 14:53:22 UTC 2023


  Branch: refs/heads/openssl-3.1
  Home:   https://github.com/openssl/openssl
  Commit: 4cfae921af8809c1f1dd567629c6c3310a9218ca
      https://github.com/openssl/openssl/commit/4cfae921af8809c1f1dd567629c6c3310a9218ca
  Author: besher <beshoux at outlook.fr>
  Date:   2023-02-08 (Wed, 08 Feb 2023)

  Changed paths:
    M apps/s_server.c

  Log Message:
  -----------
  Fix a potential memory leak in apps/s_server.c

Allocate memory for a new SSL session.
If any of these steps fail,
free the key memory and the tmpsess object
before returning 0 to prevent a memory leak.

Fixes: #20110

CLA: trivial

Reviewed-by: Paul Yang <kaishen.yy at antfin.com>
Reviewed-by: Tomas Mraz <tomas at openssl.org>
Reviewed-by: Paul Dale <pauli at openssl.org>
Reviewed-by: Todd Short <todd.short at me.com>
(Merged from https://github.com/openssl/openssl/pull/20213)

(cherry picked from commit 8e2552b1eac4957214fed55457f64d7d5164ca37)




More information about the openssl-commits mailing list