]> git.ipfire.org Git - thirdparty/haproxy.git/commit
BUG/MEDIUM: mux-h2: Propagate term flags to SE on error in h2s_wake_one_stream
authorChristopher Faulet <cfaulet@haproxy.com>
Thu, 1 Aug 2024 14:22:41 +0000 (16:22 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Fri, 2 Aug 2024 06:42:28 +0000 (08:42 +0200)
commit184f16ded7a0274bffe99a4795d0a27f8be7c006
treec77f56530a85a6e85efd7ef4852966504b338189
parent6743e128f34fba297f2cac836a4f11b84acd503a
BUG/MEDIUM: mux-h2: Propagate term flags to SE on error in h2s_wake_one_stream

When a stream is explicitly woken up by the H2 conneciton, if an error
condition is detected, the corresponding error flag is set on the SE. So
SE_FL_ERROR or SE_FL_ERR_PENDING, depending if the end of stream was
reported or not.

However, there is no attempt to propagate other termination flags. We must
be sure to properly set SE_FL_EOI and SE_FL_EOS when appropriate to be able
to switch a pending error to a fatal error.

Because of this bug, the SE remains with a pending error and no end of
stream, preventing the applicative stream to trully abort it. It means on
some abort scenario, it is possible to block a stream infinitely.

This patch must be backported at least as far as 2.8. No bug was observed on
older versions while the same code is inuse.
src/mux_h2.c