Files
Mounir IDRASSI 9dc049e97a Fix SSL_poll() multi-reactor cleanup deadlock
SSL_poll() cleaned up QUIC reactor wait registrations in item-array
order. Leaving a reactor can block while its notifier is signalled, so
two callers spanning the same reactors could each wait on one reactor
while still registered on another. The translation abort path has the
same ordering problem.

Split QUIC leave into two phases: deregister from every QUIC reactor,
then wait for any notification cycles still pending. For QUIC-only poll
sets this removes every waiter registration before any notifier wait.
DTLS listener cleanup is unchanged. Guard the QUIC drain call for
no-quic builds.

Phase 2 also prevents an immediate re-registration from keeping the
notifier signalled. Capture notify_generation during deregistration so a
wait is bounded to the observed cycle. Apply the same generation bound
to the combined single-reactor leave operation.

Exercise real SSL_poll cleanup on two reactors in both the post-poll and
translation-abort paths, including repeated items sharing a reactor.
Check that a delayed phase-2 waiter completes while a later notification
cycle remains signalled.

Fixes #32130

Assisted-by: OpenCode:GLM-5.2
Assisted-by: Codex:gpt-5.6-sol
Assisted-by: Codex:gpt-6-astra
Reviewed-by: Tomas Mraz <tomas@openssl.foundation>
Reviewed-by: Neil Horman <nhorman@openssl.org>
Merge-date: Tue Oct 20 12:29:05 2026
Merged-from: https://github.com/openssl/openssl/pull/32137
(cherry picked from commit 9682b1123a)
2026-10-20 14:30:39 +02:00
..
2026-09-29 14:02:59 +00:00
2026-10-19 12:20:49 +11:00