]> git.ipfire.org Git - thirdparty/haproxy.git/commit
MEDIUM: proxy: Reject some header names for 'http-send-name-header' directive
authorChristopher Faulet <cfaulet@haproxy.com>
Thu, 28 Aug 2025 13:05:57 +0000 (15:05 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Fri, 29 Aug 2025 07:27:01 +0000 (09:27 +0200)
commit8f3b537547af9114416ff873228b2021995c9cea
tree3f5ae3e7006784334352e0708ac6e16720c7734f
parent2afcba1eb72b10cec410759d642688f96f9341e4
MEDIUM: proxy: Reject some header names for 'http-send-name-header' directive

From time to time, we saw the 'http-send-name-header' directive used to
overwrite the Host header to workaround limitations of a buggy application.
Most of time, this led to troubles. This was never officially supported and
each time we strongly discouraged anyone to do so. We already thought to
deprecate this directive, but it seems to be still used by few people. So
for now, we decided to strengthen the tests performed on it.

The header name is now checked during the configuration parsing to forbid
some risky names. 'Host', 'Content-Length', 'Transfer-Encoding' and
'Connection' header names are now rejected. But more headers could be added
in future.
doc/configuration.txt
src/cfgparse-listen.c