BUG/MEDIUM: h3: parse content-length and reject invalid messages
authorAmaury Denoyelle <adenoyelle@haproxy.com>
Thu, 8 Dec 2022 15:54:42 +0000 (16:54 +0100)
committerAmaury Denoyelle <adenoyelle@haproxy.com>
Wed, 14 Dec 2022 10:37:12 +0000 (11:37 +0100)
commitd2c5ee665ea2d812056cb24edbca31dc42e5d246
treef4d780525c38b26ffe215c2d76f0bbe11cabbc53
parent15f3cc4b389d1e92f7d537a2321ad027cf3b5a15
BUG/MEDIUM: h3: parse content-length and reject invalid messages

Ensure that if a request contains a content-length header it matches
with the total size of following DATA frames. This is conformance with
HTTP/3 RFC 9114.

For the moment, this kind of errors triggers a connection close. In the
future, it should be handled only with a stream reset. To reduce
backport surface, this will be implemented in another commit.

This must be backported up to 2.6. It relies on the previous commit :
  MINOR: http: extract content-length parsing from H2
src/h3.c