Gossamer Forum
Home : Products : Gossamer Forum : Development, Plugins and Globals :

setting REMOTE_ADDR = HTTP_X_FORWARDED_FOR

Quote Reply
setting REMOTE_ADDR = HTTP_X_FORWARDED_FOR
Hi,

I use a 2-apache server setup. Static docs are on a "lite" build of apache. mod_perl apps get forwarded to a "heavy" build of apache via mod_proxy. (I set it up according to this: http://modperlbook.org/html/ch12_03.html)

My problem is that REMOTE_ADDR is being set to 127.0.0.1 instead of the users actual ip address. The correct ip is in the env variable X_FORWARDED_FOR.

Is there a hook I can add to set REMOTE_ADDR equal to X_FORWARDED_FOR? This would have to happen before the forum makes any use of the REMOTE_ADDR variable. I just don't know where that would be.

Last edited by:

xev: Jun 16, 2005, 8:16 AM
Subject Author Views Date
Thread setting REMOTE_ADDR = HTTP_X_FORWARDED_FOR xev 5232 Jun 16, 2005, 7:55 AM
Thread Re: [xev] setting REMOTE_ADDR = HTTP_X_FORWARDED_FOR
xev 5091 Jun 16, 2005, 9:46 AM
Thread Re: [xev] setting REMOTE_ADDR = HTTP_X_FORWARDED_FOR
Andy 5089 Jun 16, 2005, 11:03 AM
Post Re: [Andy] setting REMOTE_ADDR = HTTP_X_FORWARDED_FOR
paulj 5073 Jun 25, 2005, 4:59 PM