]> git.ipfire.org Git - thirdparty/haproxy.git/commit
BUG/MEDIUM: quic: reset padding when building GSO datagrams
authorAmaury Denoyelle <adenoyelle@haproxy.com>
Tue, 12 Aug 2025 15:27:03 +0000 (17:27 +0200)
committerAmaury Denoyelle <adenoyelle@haproxy.com>
Fri, 22 Aug 2025 14:22:01 +0000 (16:22 +0200)
commitfc3ad50788ed5e5751650ff16976a25c21b38595
treec7f6994e9a86c119945f5504e53778def8926405
parent0dc8d8d027114262bc470d94ecc2664523961446
BUG/MEDIUM: quic: reset padding when building GSO datagrams

qc_prep_pkts() encodes input data into QUIC packets in a loop into one
or several datagrams. It supports GSO which requires to built a serie of
multiple datagrams of the same length.

Each packet encoding is performed via a call to qc_do_build_pkt(). This
function has an argument to specify if output packet must be completed
with a PADDING frame. This option is activated when qc_prep_pkts()
encodes the last packet of a datagram with at least one INITIAL packet
in it.

Padding is resetted each time a new datagram is started. However, this
was not performed if GSO is used to built the next datagram. This patch
fixes it by properly resetting padding in this case also.

The impact of this bug is unknown. It may have several effectfs, one of
the most obvious being the insertion of unnecessary padding in packets.
It could also potentially trigger an infinite loop in qc_prep_pkts(),
although this has never been encountered so far.

This must be backported up to 3.1.
src/quic_tx.c