-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Rainer,

On 3/10/2009 12:19 PM, Rainer Jung wrote:
> 1) There is no standard http header named REMOTE_ADDR. Not even within
> Tomcat. So whatever you get out of this header depends completely on
> whoever set it for you. It might not exist or contain garbage.

Sure there is. It's been there forever:

http://hoohoo.ncsa.uiuc.edu/cgi/env.html
http://www.ietf.org/rfc/rfc3875

> 2) getRemoteAddr() gives you the address of the system, which opened the
> connection. In case of an AJP connector, this is not true, because AJP
> is meant to be used for reverse proxies. So here you get the address of
> the system which opened the connection to the web server, forwarded via
> AJP to Tomcat.

[snip]

> 4) Usually Reverse Proxies set a non-standard header X-Forwarded-For.
> E.g. mod_proxy does. Be warned though, that cascading Reverse Proxies
> will most likely add to the header, so it can contain multiple
> addresses, usually comma-separated.

Does mod_jk set any of these headers?

X-Forwarded-For
X-Forwarded-Host
X-Forwarded-Server

Thanks,
- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAkm4JD0ACgkQ9CaO5/Lv0PAvCACgqKdhdh88VaP7LG297RFuOv/m
5hgAoImJMS41Ms0mA7+8gXuHaMujAv13
=FNum
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to