atom feed11 messages in ru.sysoev.nginxRe: nginx and thttpd + cgi, remote_ad...
FromSent OnAttachments
Кирюшкин ВладимирOct 25, 2011 2:10 pm 
Francis DalyOct 25, 2011 3:09 pm 
Кирюшкин ВладимирOct 25, 2011 3:16 pm 
Aleksandar LazicOct 25, 2011 3:39 pm 
Francis DalyOct 26, 2011 6:02 am 
Igor SysoevOct 26, 2011 7:26 am 
Кирюшкин ВладимирOct 26, 2011 7:32 am 
Кирюшкин ВладимирOct 26, 2011 8:48 am 
Aleksandar LazicOct 26, 2011 8:50 am 
Кирюшкин ВладимирOct 26, 2011 1:37 pm 
Aleksandar LazicOct 26, 2011 2:01 pm 
Subject:Re: nginx and thttpd + cgi, remote_addr = 127.0.0.1
From:Кирюшкин Владимир (vk@jasystem.net)
Date:Oct 26, 2011 7:32:39 am
List:ru.sysoev.nginx

Hello,

26.10.2011, 17:02, "Francis Daly" <fran@daoine.org>:

Test the thttpd side:

curl -H 'X-Forwarded-For: 127.0.0.2' http://[thttpd-server]/env.cgi

If you don't see REMOTE_ADDR=127.0.0.2, then your thttpd is not acting as you expect. Nothing nginx can do can help you in that case.

localhost> curl -H 'X-Forwarded-For: 127.0.0.2'
http://***myserver***:8000/index.cgi | grep -i remote % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 471 0 471 0 0 3007 0 --:--:-- --:--:-- --:--:-- 5962 REMOTE_ADDR=***myrealip***

myserver# grep -i x-forward /ramdisk/nginx_debug.log 2011/10/26 17:20:08 [debug] 11877#0: *3 http header: "X-Forwarded-For:
127.0.0.2"

well, seems that it's thttpd issue.

26.10.2011, 18:26, "Igor Sysoev" <ig@sysoev.ru>:

You may want to use mini_httpd instead of thttpd. There is patch to support "X-Real-IP" header in mini_httpd: http://mailman.nginx.org/pipermail/nginx/2010-October/023292.html

thanks, i'll follow your advice.

Cheers,

Vladimir