Proxy IP instead real IP

Hi,

I have installed Piwik 1.1 in an Official Goverment site. The site has an architecture with proxy 10.20.5.38.
In the register of the visitors, always i have as IP visitor the IP proxy address instead of the real one. Do you know how can i have the real one?

Thanks in advance,

Eva

In core/global.ini.php, there are examples on configuring proxy headers.

In your config/config.ini.php add (depending on your environment):


[General]
proxy_client_headers[] = HTTP_X_FORWARDED_FOR
proxy_host_headers[] = HTTP_X_FORWARDED_HOST

Hi vipsoft!

Thanks for your quick answer.
I was checking and i was wrong because the version i have installed is the 1.0. In this version, i do not find any global.ini.php in core directory but in config there is one.
I added in config.ini.php the two lines you told me but still i have the problem. Should it be because i have to add in General reverse_proxy=1? Should i update piwik to ver 1.1.1?

Thank you,

Eva

Hi,

I would like to send the topology, it could be helpful.

Thanks again,

Eva

Yes you must update to 1.1.1

See also reverse proxy FAQ: Installation - Analytics Platform - Matomo