rack-devel archive mirror (unofficial) https://groups.google.com/group/rack-devel
 help / color / mirror / Atom feed
* Mongrel handler doesn't set env[REMOTE_ADDR] with the value of "X-Forwarded-For" header
@ 2009-09-13 15:52 Iñaki Baz Castillo
  2009-09-13 21:51 ` Michael Fellinger
  0 siblings, 1 reply; 5+ messages in thread
From: Iñaki Baz Castillo @ 2009-09-13 15:52 UTC (permalink / raw)
  To: rack-devel


Hi, usually when a http proxy routes a request it adds a "X-Forwarded-For: 
CLIENT_IP" to the request so the web server can know the client IP of the 
request.

In fact, using Thin handler, env[REMOTE_ADDR] is set to the value of
X-Forwarded-For header (if present).

However using Mongrel or Webrick handlers it doesn't occur and 
env[REMOTE_ADDR] is set to the http proxy IP.

Anyhow I don't see it described in Rack specifications so perhaps it's not 
mandatory.

-- 
Iñaki Baz Castillo <ibc@aliax.net>

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2009-09-13 22:44 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-09-13 15:52 Mongrel handler doesn't set env[REMOTE_ADDR] with the value of "X-Forwarded-For" header Iñaki Baz Castillo
2009-09-13 21:51 ` Michael Fellinger
2009-09-13 22:08   ` Iñaki Baz Castillo
2009-09-13 22:14     ` Aman Gupta
2009-09-13 22:44       ` Iñaki Baz Castillo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).