X-Forwarded-Proto / X_FORWARDED_PROTO

skaar skaar at waste.org
Sat Jan 9 18:29:03 EST 2010

> The Rack (and CGI) specs require that '-' be replaced with '_' for
> HTTP header names, so Unicorn is doing the correct thing and treating
> it as the same header.

but should it aggregate the values?
> Even though '_' appears to be allowed in header names by rfc 2616, it's
> use is questionable as there are parsers that reject it.  Any chance of
> fixing whatever sends the "X_FORWARDED_PROTO" header?  It's completely
> pointless to set to "http"

in our case we can probably fix the proxy chain - we have a set of
dedicated SSL systems (which sets X-Forwarded-Proto) which forward to
the main nginx front end (which sets X_FORWARDED_PROTO). I'll also look
at removing the proxy-set-header cases that sets it to to 'http'.

Just for reference: we ran into this issue when replacing nginx to
mongrels over a TCP socket, with nginx to unicorn over a domain socket.
With mongrel we don't have this problem (although I see from
e26ebc985b882c38da50fb0104791a5f2c0f8522 - that you added support for it
in http11)


> -- 
> Eric Wong
> _______________________________________________
> Unicorn mailing list - mongrel-unicorn at rubyforge.org
> http://rubyforge.org/mailman/listinfo/mongrel-unicorn
> Do not quote signatures (like this one) or top post when replying


skaar at waste.org
where in the W.A.S.T.E is the wisdom

More information about the mongrel-unicorn mailing list