From 61290ec774b311edad0285b90fab979a420d252c Mon Sep 17 00:00:00 2001 From: Willy Tarreau Date: Tue, 17 Oct 2017 08:19:21 +0200 Subject: [PATCH] MINOR: h2: handle CONTINUATION frames For now we have nowhere to store partial header frames so we can't handle CONTINUATION frames and we must reject them. In this case we respond with a stream error of type INTERNAL_ERROR. --- src/mux_h2.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/mux_h2.c b/src/mux_h2.c index 72a4b507e..7d828b140 100644 --- a/src/mux_h2.c +++ b/src/mux_h2.c @@ -1204,6 +1204,15 @@ static void h2_process_demux(struct h2c *h2c) ret = h2c_handle_window_update(h2c, h2s); break; + case H2_FT_CONTINUATION: + /* we currently don't support CONTINUATION frames since + * we have nowhere to store the partial HEADERS frame. + * Let's abort the stream on an INTERNAL_ERROR here. + */ + if (h2c->st0 == H2_CS_FRAME_P) + h2s_error(h2s, H2_ERR_INTERNAL_ERROR); + break; + /* FIXME: implement all supported frame types here */ default: /* drop frames that we ignore. They may be larger than