]> git.ipfire.org Git - thirdparty/haproxy.git/commit
BUG/MINOR: quic-be: Malformed coalesced Initial packets
authorFrederic Lecaille <flecaille@haproxy.com>
Wed, 2 Jul 2025 14:37:02 +0000 (16:37 +0200)
committerFrederic Lecaille <flecaille@haproxy.com>
Mon, 7 Jul 2025 12:13:02 +0000 (14:13 +0200)
commit87ada46f38054e4debb852ae4b98feec4676f4af
treed4e39b25ce0b917aa1f30e5b9325b2791368bdce
parent6aebca7f2cc443fb917b495def86b56f15dfcd63
BUG/MINOR: quic-be: Malformed coalesced Initial packets

This bug fix completes this patch which was not sufficient:

   MINOR: quic-be: Allow sending 1200 bytes Initial datagrams

This patch could not allow the build of well formed Initial packets coalesced to
others (Handshake) packets. Indeed, the <padding> parameter passed to qc_build_pkt()
is deduced from a first value: <padding> value and must be set to 1 for
the last encryption level. As a client, the last encryption level is always
the Handshake encryption level. But <padding> was always set to 1 for a QUIC
client, leading the first Initial packet to be malformed because considered
as the second one into the same datagram.

So, this patch sets <padding> value passed to qc_build_pkt() to 1 only when there
is no last encryption level at all, to allow the build of Initial only packets
(not coalesced) or when it frames to send (coalesced packets).

No need to backport.
src/quic_tx.c