Opened 13 years ago

Closed 13 years ago

#155 closed defect (duplicate)

ngx_http_realip_module bug

Reported by: Lele Li Owned by: somebody
Priority: critical Milestone:
Component: nginx-module Version: 1.0.x
Keywords: real ip Cc:
uname -a: 2.6.18-164.el5
nginx -V: nginx version: nginx/0.8.55

Description

we use ngx_http_realip_module ,but we can't get the real ip address when the nginx receive http header like this :

X-Forwarded-For: 10.18.18.18, 120.196.208.118
the ngx_http_realip_module event didn't work ,it don't change the client ip address

when we send nginx two or three X-Forwarded-For like this:

GET / HTTP/1.1
Host: text.test.com
Accept-Encoding: gzip,deflate
Cookie: vt=3; ustat=a774e85f181eb0b70d6dbcb40184f246
Accept-Language: zh-cn
Accept-Charset: x-gbk,utf-8;q=0.7,*;q=0.7
Cache-Control: max-age=0
x-forwarded-for: 10.18.18.18
X-Forwarded-For: 120.196.208.118
X-Forwarded-For: 221.179.192.111
Connection: close

it use the first x-forwarded-for change the client ip but not the last one.


Change History (1)

comment:1 by Ruslan Ermilov, 13 years ago

Resolution: duplicate
Status: newclosed

First case is duplicate of #2, second case is duplicate of #106.

Note: See TracTickets for help on using tickets.