Piwik doesn't save HTTP_X_FORWARDED_FOR


#1

Hi all,

I’m using piwik 2.13.1 behind apache reverse proxy.

I have set proxy_client_headers[] = HTTP_X_FORWARDED_FOR in [General] section of config.ini.php but in statistics I can see only ip address of reverse proxy.

I used tcpdump on piwik host to see http header and I saw
X-Forwarded-For: xxx.xxx.xxx.xxx (correct ip client address)

So header variable is setted but piwik doesn’t save it in visits table.

Can someone help me?
Thanks


(Matthieu Aubry) #2

Hi there,

it should work I think, but it’s possible there is a bug.

Can you also try to add:

proxy_host_headers[] = HTTP_X_FORWARDED_HOST


#3

Hi Matt,

now it’s work! This is very strange. I don’ have changed configuration, but after some hour visitors are logged correctly.