[openssl/openssl] c5597b: CONF_modules_unload should fail if CONF_modules_fi...

matt noreply at reply.github.openssl.org
Mon Jun 6 06:54:21 UTC 2022


  Branch: refs/heads/openssl-3.0
  Home:   https://github.openssl.org/openssl/openssl
  Commit: c5597b2f076fb33b88f318127df8a4f65f587c6b
      https://github.openssl.org/openssl/openssl/commit/c5597b2f076fb33b88f318127df8a4f65f587c6b
  Author: Matt Caswell <matt at openssl.org>
  Date:   2022-06-06 (Mon, 06 Jun 2022)

  Changed paths:
    M crypto/conf/conf_mod.c

  Log Message:
  -----------
  CONF_modules_unload should fail if CONF_modules_finish fails

The module_list_lock is used by CONF_modules_unload(). That function relies
on the RUN_ONCE in CONF_modules_finish() to initialise that lock. However
if the RUN_ONCE fails that failure is not propagated to
CONF_modules_unload() and so it erroneously tries to use the lock anyway.

Found due to:
https://github.com/openssl/openssl/pull/18355#issuecomment-1144734604

Reviewed-by: Todd Short <todd.short at me.com>
Reviewed-by: Tomas Mraz <tomas at openssl.org>
(Merged from https://github.com/openssl/openssl/pull/18460)

(cherry picked from commit 697d0b5ba146c232f5b2aa87f4e847a5495c1735)




More information about the openssl-commits mailing list