https://bz.apache.org/bugzilla/show_bug.cgi?id=61010
Bug ID: 61010
Summary: ProxyPreserveHost Not working as documented
Product: Apache httpd-2
Version: 2.4.6
Hardware: PC
Status: NEW
Severity: normal
Priority: P2
Component: mod_proxy
Assignee: [email protected]
Reporter: [email protected]
Target Milestone: ---
https://httpd.apache.org/docs/2.4/mod/mod_proxy.html#proxypreservehost
Says:
When enabled, this option will pass the Host: line from the incoming request to
the proxied host, instead of the hostname specified in the ProxyPass line.
However, when I setup a ProxyPass:
<Location /en_US>
ProxyPass "http://othersite.com"
</Location>
The othersite.com was receiving mysite.com as the HOST header.
Adding ProxyPreserveHost Off or ProxyPreserveHost On made no difference.
When I changed the config to
<Location /en_US>
RequestHeader set Host othersite.com
ProxyPass "http://othersite.com"
</Location>
It worked perfectly.
Seems like a bug. Am I misunderstanding?
httpd -V
Server version: Apache/2.4.6 (Red Hat Enterprise Linux)
Server built: Sep 17 2015 09:06:30
Server's Module Magic Number: 20120211:24
Server loaded: APR 1.4.8, APR-UTIL 1.5.2
Compiled using: APR 1.4.8, APR-UTIL 1.5.2
Architecture: 64-bit
Server MPM: prefork
threaded: no
forked: yes (variable process count)
Server compiled with....
-D APR_HAS_SENDFILE
-D APR_HAS_MMAP
-D APR_HAVE_IPV6 (IPv4-mapped addresses enabled)
-D APR_USE_SYSVSEM_SERIALIZE
-D APR_USE_PTHREAD_SERIALIZE
-D SINGLE_LISTEN_UNSERIALIZED_ACCEPT
-D APR_HAS_OTHER_CHILD
-D AP_HAVE_RELIABLE_PIPED_LOGS
-D DYNAMIC_MODULE_LIMIT=256
-D HTTPD_ROOT="/etc/httpd"
-D SUEXEC_BIN="/usr/sbin/suexec"
-D DEFAULT_PIDLOG="/run/httpd/httpd.pid"
-D DEFAULT_SCOREBOARD="logs/apache_runtime_status"
-D DEFAULT_ERRORLOG="logs/error_log"
-D AP_TYPES_CONFIG_FILE="conf/mime.types"
-D SERVER_CONFIG_FILE="conf/httpd.conf"
I'll try a newer version to see if that makes any difference.
--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]