]> git.ipfire.org Git - thirdparty/haproxy.git/commit
MINOR: h1: permit to relax the websocket checks for missing mandatory headers
authorWilly Tarreau <w@1wt.eu>
Fri, 28 Feb 2025 12:35:13 +0000 (13:35 +0100)
committerWilly Tarreau <w@1wt.eu>
Fri, 28 Feb 2025 16:31:20 +0000 (17:31 +0100)
commitfd5d59967ad780563298a176db6e657f22831d50
tree49f454eaca1f427efaf65f19c5f9a57a56976643
parent0e08252294d5a7389ad42b51b4b931fab2e66f31
MINOR: h1: permit to relax the websocket checks for missing mandatory headers

At least one user would like to allow a standards-violating client setup
WebSocket connections through haproxy to a standards-violating server that
accepts them. While this should of course never be done over the internet,
it can make sense in the datacenter between application components which do
not need to mask the data, so this typically falls into the situation of
what the "accept-unsafe-violations-in-http-request" option and the
"accept-unsafe-violations-in-http-response" option are made for.
See GH #2876 for more context.

This patch relaxes the test on the "Sec-Websocket-Key" header field in
the request, and of the "Sec-Websocket-Accept" header in the response
when these respective options are set.

The doc was updated to reference this addition. This may be backported
to 3.1 but preferably not further.
doc/configuration.txt
src/mux_h1.c