search for: http_x_forwarded_host

Displaying 9 results from an estimated 9 matches for "http_x_forwarded_host".

2009 Jun 25
1
request.host, proxy chains and HTTP_X_FORWARDED_HOST
...where used). All is fine there. However, in controllers, url_for generates a full url, with the host name. This causes problems when we have a chain of Apache proxy servers: My Browser ---> Proxy 1 ----> Proxy 2 ----> Phusion Deployment Server. In this scenario, the request header item HTTP_X_FORWARDED_HOST contains the following: proxy1:81, proxy2 Rails extracts the host by splitting this string and getting the last item: (actionpack-2.3.2\lib\action_controller\request.rb line 271) def raw_host_with_port if forwarded = env["HTTP_X_FORWARDED_HOST"] forwarded.split(/,\s?...
2006 Jan 07
0
rails behind multiple proxies
...lem has come up because I have a few rails application on an intranet where I have to use proxies to provide access to some clients. I have done little work with this sort of thing before so I was hoping to get more input from someone on this list. When multiple proxies have serviced a request the HTTP_X_FORWARDED_HOST environment variable is created and looks like this: HTTP_X_FORWARDED_HOST = "www.firsthost.org, www.secondhost.org" In this case the browser requested a url from www.firsthost.org, which then forwarded this request to www.secondhost.org which then forwarded this to the rails applicatio...
2008 Jul 20
4
how does request.host get set?
how does request.host get set? Is there a way to manually set the value in request.host? I have several application servers running rails, each has its own internal address in the request.host, so when calling redirect_to or url_for function, it uses the internal address which is not accessible to the user. what I want is to set request.host to return mysite.com, no matter which application
2007 May 30
0
Headers munged into RAW_POST_DATA
...: https://foo.com/ad_keywords/new?ad=5&cid=7 * HTTP_USER_AGENT : Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.3) Gecko/20070309 Firefox/2.0.0.3 * HTTP_VERSION : HTTP/1.0 * HTTP_X_BROWSER_TIMESTAMP: 386789 * HTTP_X_FORWARDED_FOR : xx.xxx.xxx.xxx * HTTP_X_FORWARDED_HOST : foo.com * HTTP_X_FORWARDED_PROTO : https * HTTP_X_FORWARDED_SERVER : foo.com * HTTP_X_NAVID : f5c-50cfb * PATH_INFO : /ad_keywords/new * QUERY_STRING : cid=7&ad=5&ct= * RAW_POST_DATA : Connection: Keep-Alive ad_keyword%5Bsmart...
2007 May 29
1
Headers munged into RAW_POST_DATA
...tps://foo.com/ad_keywords/new? ad=5&cid=7 * HTTP_USER_AGENT : Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.3) Gecko/20070309 Firefox/2.0.0.3 * HTTP_VERSION : HTTP/1.0 * HTTP_X_BROWSER_TIMESTAMP: 386789 * HTTP_X_FORWARDED_FOR : xx.xxx.xxx.xxx * HTTP_X_FORWARDED_HOST : foo.com * HTTP_X_FORWARDED_PROTO : https * HTTP_X_FORWARDED_SERVER : foo.com * HTTP_X_NAVID : f5c-50cfb * PATH_INFO : /ad_keywords/new * QUERY_STRING : cid=7&ad=5&ct= * RAW_POST_DATA : Connection: Keep-Alive ad_keyword%...
2008 Apr 17
0
Error log, when using apache2.2.x modproxy with mongrel
.../*;q=0.8\r\nAccept-Language: zh-tw,en-us;q=0.7,en;q=0.3\r\nAccept-Encoding: gzip,deflate\r\nAccept-Charset: Big5,utf-8;q=0.7,*;q=0.7\r\nX-Forwarded-For: 127.0.0.1\r\nX-Forwarded-Host: www.testkoji.com\r\nX-Forwarded-Server: www.testkoji.com\r\nConnection: Keep-Alive\r\n\r\n" --- PARAMS: {"HTTP_X_FORWARDED_HOST"=>"www.testkoji.com", "HTTP_ACCEPT_ENCODING"=>"gzip,deflate", "HTTP_USER_AGENT"=>"Mozilla/5.0 (Windows; U; Windows NT 5.1; zh-TW; rv:1.9b5) Gecko/2008032620 Firefox/3.0b5", "HTTP_ACCEPT_LANGUAGE"=>"zh-tw,en-us;q=0.7,e...
2012 Feb 10
2
My Host
I need to get some absolute redirects working -- basically I set callback hooks to external services, but I want these hooks to use my configured CNAME''s. I''m trying to find a way so that my app doesn''t have to know about these CNAME''s. So I''m looking at the request in the controller to try and get the base URL where I''m running. To
2006 Jul 09
3
Mongrel and proxying with Apache 2 mod_proxy
...vent code in there was done to resolve a proxy issue with lighttp. Unfortunately, that same code seems to not work with Apache 2.x mod_proxy. Hacky Solution ============== I hacked actionpack-1.12.3/lib/action_controller/cgi_process.rb host_with_port method so that it didn''t look at the HTTP_X_FORWARDED_HOST at all. The apache configuration for coolapps.com includes the following proxy directives ProxyPass /nice/ http://super.secret.com:3000/ <Location /nice/> ProxyPassReverse / SetOutputFilter proxy-html ProxyHTMLURLMap / /nice/ ProxyHTMLURLMap...
2007 Jun 28
1
DRb server crashing
...: http://75.126.217.82/forums/writeroom/topics/18_WR_1_document_model/comments/new * HTTP_USER_AGENT : Mozilla/5.0 (Macintosh; U; PPC Mac OS X; sv-se) AppleWebKit/419.2.1 (KHTML, like Gecko) Safari/419.3 * HTTP_VERSION : HTTP/1.1 * HTTP_X_FORWARDED_FOR : 213.185.4.64 * HTTP_X_FORWARDED_HOST : 75.126.217.82 * HTTP_X_FORWARDED_SERVER: www.jesse-grosjean-temp.com * PATH_INFO : /forums/writeroom/topics/18_WR_1_document_model/comments * RAW_POST_DATA : [FILTERED] * REMOTE_ADDR : 213.185.4.64 * REQUEST_METHOD : POST * REQUEST_PATH...