]> git.kaiwu.me - haproxy.git/commit
BUG/MAJOR: h3: reject H3 truncated frames
authorAmaury Denoyelle <adenoyelle@haproxy.com>
Thu, 3 Sep 2026 12:50:05 +0000 (14:50 +0200)
committerAmaury Denoyelle <adenoyelle@haproxy.com>
Thu, 3 Sep 2026 13:55:36 +0000 (15:55 +0200)
commit86a4ebc761a278838e8cb06f3a292282ba704c65
tree7a0daa899961d3ba076f0426480a6147b130798a
parent55b6e5496edebabacafe9ae4456c31bc210610d0
BUG/MAJOR: h3: reject H3 truncated frames

HTTP/3 frames contain a length header. If a frame is truncated, the
connection must be immediately closed with H3_FRAME_ERROR.

This patch adds missing check for truncated frames when FIN is received.
This must be tested in two locations. First, a check is added in the
standalone FIN dedicated block. Second, another check is implemented in
the default parsing while loop, tested on every iteration as large DATA
frames can be read as streaming content.

These checks are crucial to prevent potential request content smuggling.

Thanks to Rajat Raghav for its report which reveal this issue.

This must be backported to all stable releases.
src/h3.c