]> git.ipfire.org Git - thirdparty/haproxy.git/commit
BUG/MEDIUM: mux-fcgi: Properly handle EOM flag on end-of-trailers HTX block
authorChristopher Faulet <cfaulet@haproxy.com>
Mon, 25 Mar 2024 07:02:06 +0000 (08:02 +0100)
committerChristopher Faulet <cfaulet@haproxy.com>
Mon, 25 Mar 2024 10:06:41 +0000 (11:06 +0100)
commit56c4b29ff1e7df05201fa736aa3f35307443f73b
tree01b66d7ae4960c9a6a4e09708be0761cc3fde690
parentbd384a359b443aadb6552971248c007932e4c1e2
BUG/MEDIUM: mux-fcgi: Properly handle EOM flag on end-of-trailers HTX block

Trailers are skipped by the FCGI multiplexer. However empty chunked messages
are not properly handled. It may be a chunked H1 request with no payload or
a H2/H3 POST request with no payload. In that caes, the EOT HTX block is
just ignored. The issue is that the EOM flag is thus ignored too. It means
no empty STDIN record is sent to mark the end of the request to the server.

To fix the issue, when a EOT htx block is found and it is the last HTX block
of the message (and it should be), the EOM flag is tested. If it is found,
an empty STDIN record is emitted.

This patch should fix the issue #2499. It must be backported as far as 2.4.
src/mux_fcgi.c