]> git.kaiwu.me - haproxy.git/commit
BUG/MEDIUM: h3: fix incorrect DATA size block on DEM FULL
authorAmaury Denoyelle <adenoyelle@haproxy.com>
Thu, 8 Oct 2026 17:24:20 +0000 (19:24 +0200)
committerAmaury Denoyelle <adenoyelle@haproxy.com>
Thu, 8 Oct 2026 18:12:20 +0000 (20:12 +0200)
commitfe8a8c322e593d5752c1f9cacbc3a35492382f6e
tree114d0d5812d1fb5f9d809248efc6c03d4248e4b1
parent9a624656d8fe31a5429cd9c2db3b284ee84f2e0d
BUG/MEDIUM: h3: fix incorrect DATA size block on DEM FULL

The following patch fixes h3_data_to_htx() to ensure the correct value
is returned in case of buffer wrapper.

  bcdbc399d34f82a21c49162f203f2ff16b0aed79
  BUG/MEDIUM: h3: fix end-of-input report on DATA wrapping

However, this introduces a regression when HTX buffer is smaller than
the copied block. In this case, QCS is flagged with QC_SF_DEM_FULL, but
early goto skip the increment on <htx_sent> total value.

This causes corrupted transfers with H3 POST larger than a bufsize
resulting in a larger payload. This is caused by duplicated data blocks
when copy resumes after hitting QC_SF_DEM_FULL condition.

Fix this by ensuring <htx_sent> is always updated before the early goto
path. Intent of the above fix is kept as well as <ret> still serves as a
comparison for QC_SF_DEM_FULL / EOM cases.

This must be backported along the above patch, planned up to 2.6 (after
a period of observation).
src/h3.c