haproxy public development tree
Go to file
Willy Tarreau 96a10c24cf MINOR: mux-h2: fail stream creation more cleanly using RST_STREAM
The H2 demux only checks for too many streams in h2c_frt_stream_new(),
then refuses to create a new stream and causes the connection to be
aborted by sending a GOAWAY frame. This will also happen if any error
happens during the stream creation (e.g. memory allocation).

RFC7540#5.1.2 says that attempts to create streams in excess should
instead be dealt with using an RST_STREAM frame conveying either the
PROTOCOL_ERROR or REFUSED_STREAM reason (the latter being usable only
if it is guaranteed that the stream was not processed). In theory it
should not happen for well behaving clients, though it may if we
configure a low enough h2.max_concurrent_streams limit. This error
however may definitely happen on memory shortage.

Previously it was not possible to use RST_STREAM due to the fact that
the HPACK decompressor would be desynchronized. But now we first decode
and only then try to allocate the stream, so the decompressor remains
synchronized regardless of policy or resources issues.

With this patch we enforce stream termination with RST_STREAM and
REFUSED_STREAM if this protocol violation happens, as well as if there
is a temporary condition like a memory allocation issue. It will allow
a client to recover cleanly.

This could possibly be backported to 1.9. Note that this requires that
these five previous patches are merged as well :

    MINOR: h2: add a bit-based frame type representation
    MEDIUM: mux-h2: remove padlen during headers phase
    MEDIUM: mux-h2: decode HEADERS frames before allocating the stream
    MINOR: mux-h2: make h2c_send_rst_stream() use the dummy stream's error code
    MINOR: mux-h2: add a new dummy stream for the REFUSED_STREAM error code
2018-12-24 11:45:00 +01:00
contrib CONTRIB: debug: report stream-int's flag SI_FL_CLEAN_ABRT 2018-12-18 11:03:11 +01:00
doc [RELEASE] Released version 2.0-dev0 2018-12-22 11:20:35 +01:00
ebtree CLEANUP: fix typos in comments in ebtree 2018-11-18 22:23:15 +01:00
examples [RELEASE] Released version 2.0-dev0 2018-12-22 11:20:35 +01:00
include MINOR: h2: add a bit-based frame type representation 2018-12-24 11:45:00 +01:00
reg-tests REGTESTS: remove the expected window updates from H2 handshakes 2018-12-23 09:58:41 +01:00
scripts REGTEST: script: Add support of alternatives in requited options list 2018-12-21 15:33:26 +01:00
src MINOR: mux-h2: fail stream creation more cleanly using RST_STREAM 2018-12-24 11:45:00 +01:00
tests CLEANUP: fix a misspell in tests/filltab25.c 2018-11-18 22:23:15 +01:00
.gitignore DOC: split the README into README + INSTALL 2018-12-16 22:30:57 +01:00
CHANGELOG [RELEASE] Released version 2.0-dev0 2018-12-22 11:20:35 +01:00
CONTRIBUTING DOC: Fix typos in README and CONTRIBUTING 2018-11-12 08:54:12 +01:00
INSTALL [RELEASE] Released version 2.0-dev0 2018-12-22 11:20:35 +01:00
LICENSE
MAINTAINERS DOC: fix reference to map files in MAINTAINERS 2018-10-17 04:21:04 +02:00
Makefile REGTEST: Make reg-tests target support argument. 2018-12-20 10:37:32 +01:00
README DOC: split the README into README + INSTALL 2018-12-16 22:30:57 +01:00
ROADMAP DOC: update the roadmap about priority queues 2018-08-10 17:12:04 +02:00
SUBVERS
VERDATE [RELEASE] Released version 2.0-dev0 2018-12-22 11:20:35 +01:00
VERSION [RELEASE] Released version 2.0-dev0 2018-12-22 11:20:35 +01:00

README

The HAProxy documentation has been split into a number of different files for
ease of use.

Please refer to the following files depending on what you're looking for :

  - INSTALL for instructions on how to build and install HAProxy
  - LICENSE for the project's license
  - CONTRIBUTING for the process to follow to submit contributions

The more detailed documentation is located into the doc/ directory :

  - doc/intro.txt for a quick introduction on HAProxy
  - doc/configuration.txt for the configuration's reference manual
  - doc/lua.txt for the Lua's reference manual
  - doc/SPOE.txt for how to use the SPOE engine
  - doc/network-namespaces.txt for how to use network namespaces under Linux
  - doc/management.txt for the management guide
  - doc/regression-testing.txt for how to use the regression testing suite
  - doc/peers.txt for the peers protocol reference
  - doc/coding-style.txt for how to adopt HAProxy's coding style
  - doc/internals for developer-specific documentation (not all up to date)