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

Products: Gossamer Forum: Development, Plugins and Globals: setting REMOTE_ADDR = HTTP_X_FORWARDED_FOR: Edit Log

Here is the list of edits for this post
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

Edit Log: