]> git.ipfire.org Git - thirdparty/openssl.git/commit
set SSLfatal if tls1_set_shared_sigalgs has a malloc failure master
authorNeil Horman <nhorman@openssl.org>
Wed, 13 Aug 2025 18:27:34 +0000 (14:27 -0400)
committerNeil Horman <nhorman@openssl.org>
Fri, 15 Aug 2025 12:39:11 +0000 (08:39 -0400)
commit389728876b51de0df9f97b6a295948ebec1e0f0c
tree36737e6d2db3d1c7d971ec6c069f8fea8acaea88
parent084a62734702caadbaf0507d580201bcb3486eaf
set SSLfatal if tls1_set_shared_sigalgs has a malloc failure

Detected another memfail failure

https://github.com/openssl/openssl/actions/runs/16926186604/job/47962169870

Tracking it back, it occurs because tls1_set_server_sigalgs attempts to
preform an allocation, and in the event of failure, returns 0 without
setting SSLfatal, like the other failure paths in this function do when
returning 0, which translates to a return of WORK_ERROR higher up the
stack

The result is that on the next call to check_fatal in
read_state_machine, we fail the assert when deubg is enabled (as it is
in the coverage tests).

Fix it by calling SSLfatal when the call to OPENSSL_calloc fails in this
function.

Reviewed-by: Saša Nedvědický <sashan@openssl.org>
Reviewed-by: Kurt Roeckx <kurt@roeckx.be>
Reviewed-by: Matt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/28250)
ssl/t1_lib.c