Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Site on IPv4 only logs IPv6 visitors #10104

Closed
mbroek opened this issue Apr 28, 2016 · 2 comments
Closed

Site on IPv4 only logs IPv6 visitors #10104

mbroek opened this issue Apr 28, 2016 · 2 comments
Labels
answered For when a question was asked and we referred to forum or answered it.

Comments

@mbroek
Copy link

mbroek commented Apr 28, 2016

I'm running a Piwik server version 2.16.1 This server is accessible via IPv4 and IPv6.
One of the servers that I monitor runs with an ISP that only has IPv4. That server logs IPv6 visitors which is impossible.
When I inspect the logs I see entries coming from a dual stack client connect via IPv4 to the IPv4 only website and connects at the same time to the piwik server using IPv6. Here are parts of the logfiles:

195.241.xx.xx - - [18/Apr/2016:13:10:21 +0200] "GET / HTTP/1.1" 200 8325 "-" "Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Firefox/38.0"

2001:xxxx:xxxx:7e97::5 - - [18/Apr/2016:13:10:21 +0200] "GET /piwik/piwik.php?action_name=Voices&idsite=14&rec=1&r=576524&h=13&m=10&s=21&url=http%3A%2F%2Fwww.zanggroepvoices.nl%2F&id=1045303909a7763c&idts=1438343396&idvc=44&idn=0&refts=0&viewts=1460977822&cs=windows-1252&send_image=0&pdf=0&qt=0&realp=0&wma=0&dir=0&fla=1&java=1&gears=0&ag=0&cookie=1&res=1920x1080&gt_ms=37 HTTP/1.1" 204 0 "http://www.zanggroepvoices.nl/" "Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Firefox/38.0" "-" "-" "0.119"

I think that in the message to the piwik server a parameters should be sent that tells the real origin of the site visit. Now it uses the origin address used on the piwik server.

@tsteur
Copy link
Member

tsteur commented May 1, 2016

It may help to configure some headers in config/config.ini.php see http://piwik.org/faq/how-to-install/faq_98/ . Does this help?

@halfdan
Copy link
Member

halfdan commented May 9, 2016

Hi @mbroek,
I think this is perfectly normal. Dual-stack clients will fetch your IPv4-only website over IPv4, then load the Piwik tracking script from your dual-stack Piwik server via IPv6 (because with dual-stack clients IPv6 is usually preferred) and then track the visit with IPv6 accordingly. Piwik has no way of knowing which protocol was used to fetch the original website.

Feel free to reopen if you have any other questions.

@halfdan halfdan closed this as completed May 9, 2016
@mattab mattab added the answered For when a question was asked and we referred to forum or answered it. label Aug 2, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
answered For when a question was asked and we referred to forum or answered it.
Projects
None yet
Development

No branches or pull requests

4 participants