How do we configure IBM HTTP Server to
set a header called "X-Forwarded-For" equal to the IP address of the
client?
Note:The X-Forwarded-For header is not
required by IBM HTTP Server (IHS) or by IBM WebSphere Application Server (WAS).
But it may be required by software from other vendors.
#######set
a header called "X-Forwarded-For" equal to the IP address of the
client######
LoadModule rewrite_module modules/mod_rewrite.so
LoadModule headers_module modules/mod_headers.so
RewriteEngine
on
RewriteRule ^(.*) - [E=CLIENT_IP:%{REMOTE_ADDR},L]
RequestHeader set x-forwarded-for %{CLIENT_IP}e
RewriteRule ^(.*) - [E=CLIENT_IP:%{REMOTE_ADDR},L]
RequestHeader set x-forwarded-for %{CLIENT_IP}e
- To configure IBM HTTP Server to set the X-Forwarded-For header to the client IP address, in a non-proxy request, you need to enable the mod_rewrite and mod_headers modules, and then add the following lines in the IBM HTTP Server config (httpd.conf):
- No configuration is necessary when IBM HTTP Server is configured as a reverse proxy, as this header is added automatically by mod_proxy_http
- more:http://en.wikipedia.org/wiki/X-Forwarded-For
Does it send X-Forwarded-For header? or the $WSRA? which would have the client IP?
ReplyDelete