You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by Vincent Deffontaines <vi...@gryzor.com> on 2011/01/15 23:19:44 UTC
[PATCH] Suggesting a new mod_proxy ProxyAddHeaders directive
Greetings,
Following a small discussion on #httpd irc channel, about
X-Forwarded-For, X-Forwarded-Host and X-Forwarded-Server.
These headers are currently set or altered by mod_proxy_http whenever a
reverse proxy request is handled.
Using RequestHeader to unset these headers is unefficient, probably for
order processing reasons. Even if it was possible, it would not be
sufficient, since an administrator might want to pass already existing
headers without altering them, rather than just unsetting them.
Here is a small patch against trunk. This patch introduces the
ProxyAddHeaders directive.
If set to "On" (default), the current mod_proxy_http behavior is kept :
X-Forwarded-* headers are set, or completed for the request sent to the
backend server.
If set to "Off", X-Forwarded-* headers are just passed as in the client
request, if defined.
I have included the documentation patch, unsure whether it should be
commited separately ?
Please comment and correct me if needed.
Vincent Deffontaines