BUG/MEDIUM: mux-h2: properly deal with too large headers frames
authorWilly Tarreau <w@1wt.eu>
Mon, 29 Apr 2019 08:20:21 +0000 (10:20 +0200)
committerWilly Tarreau <w@1wt.eu>
Mon, 29 Apr 2019 08:20:21 +0000 (10:20 +0200)
commit97215ca284fa7127f20248f00919a0d6df5b8819
treed29d7ec5d317b288a30b1a880889db85422acb40
parent4de0eba8488f7d7b471d60da76d815c69e44fecb
BUG/MEDIUM: mux-h2: properly deal with too large headers frames

In h2c_decode_headers(), now that we support CONTINUATION frames, we
try to defragment all pending frames at once before processing them.
However if the first is exactly full and the second cannot be parsed,
we don't detect the problem and we wait for the next part forever due
to an incorrect check on exit; we must abort the processing as soon as
the current frame remains full after defragmentation as in this case
there is no way to make forward progress.

Thanks to Yves Lafon for providing traces exhibiting the problem.

This must be backported to 1.9.
src/mux_h2.c