Details
-
Type:
Bug
-
Status:
Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: None
-
Fix Version/s: None
-
Component/s: None
-
Labels:None
-
Environment:Jetty HEAD
Apache 1.3.x w/mod_jk (Debian stable - 'sarge') behind NAT forwarding to Jetty (TRUNK as of Saturday 9/12/06)
-
Number of attachments :
Description
The behaviour of getRemoteHost() when using the AJP13Connector has changed since Jetty 5.0.0.
Host A (UA) – HTTP request --> Host B (Apache) — AJP13 request ---> Jetty (AJP13)
In 5.0.0, getRemoteHost() returned the address of the client behind the AJP13 host (i.e. host A in the above)
In current Jetty, getRemoteHost() returns the address of the Apache server (which is the client as far as Jetty is concerned, I suppose...)
Is this behaviour intentional? It confuses the hell out of a few things here, which serve different content depending on which side of the NAT box the user is on.
The behaviour can be demonstrated by the following two URLs:
1) Via Apache & AJP13:
http://www.wreckage.org/remotehost.jsp
(192.168.0.6 is the internal address of the host running Apache+mod_jk)
2) Direct to Jetty's SelectChannelConnector
http://www.wreckage.org:8080/remotehost.jsp