-
Notifications
You must be signed in to change notification settings - Fork 46
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
Proxy bypasses the Matomo "ignore" cookie. #58
Comments
AFAIK cookies should be forwarded in https://github.com/matomo-org/tracker-proxy/blob/master/proxy.php#L251 Is there any chance you could debug on your server or find out if the cookies are forwarded to your server or not? |
I'd be happy to debug, given some guidance (I am a coder but in entirely different fields) and a bit of time (this being a demanding month at work). Should I load one of my pages, locate the cookie in the inspector, and paste the cookie data here? What would server debugging entail in this case? (Also, @tsteur, I'd appreciate any information on using the tracker proxy with the Matomo tag manager snippet, if that's possible in the first place. Happy to open another ticket if necessary.) |
It's a good question. Problem is that cookies won't be visible in your access log etc. I'm guessing a good start would be to check if the proxy actually gets the cookie information. So for a short time in https://github.com/matomo-org/tracker-proxy/blob/master/proxy.php#L252 you could add some line var_dump($_SERVER['HTTP_COOKIE']);exit; or Then the proxy like You'd expect to see the cookie to be printed there for you. Afterwards would directly remove that line again to not break your tracking. |
@tsteur I'm finally able to debug this. I followed your instructions and got the following:
Thankful for any thoughts. |
There is no ignore cookie by the looks thus it would be tracked. Do you know which browser they use? Chrome by any chance? There were recently changes in Chrome on how they handle cookies and if your tracker proxy is running on a different domain you may need to eg call It's hard to say what could be the problem without seeing it on the site itself so it's just a guess. You'd basically need to double check is the pk_ignore cookie set in the Browser Developer Tools, and if then this is not printed in above debug line that you added, then it means the browser is not forwarding that cookie. |
Thanks, @tsteur. The ignore function fails with all major browsers (Safari, Firefox, Chrome). Here is the domain setup:
The three websites are all tracked by Matomo using the tracker proxy. The web inspector for
The web inspector for any of the three websites, on the other hand, does not show the ignore cookie. Even if the cookie isn't pushed for All websites and the Matomo installation are HTTPS-only. |
I probably had the quotes wrong, it might work when you use Are you using the latest version of Matomo? And you need to make sure https is used when proxying the request to Matomo. This should make sure that the cookie gets |
@tsteur indeed |
I see. Matomo does have a setting in [General]
cookie_domain = "" I thought you could set this setting so it uses |
Created matomo-org/matomo#15778 |
@tsteur #15778 has now been fixed but, as explained there, the present issue persists. May I suggest that we triage this? |
@yrammos sure be great if you could investigate and look into this. That be very appreciated. |
Wondering if there has been any progress on this (about 3 years later). I do not have resources to install a full-fledged build environment on my machine, but on a thorough reading of the code could not locate the issue. Many thanks for any insights or updates. |
Since installing the proxy, visits to my own websites are tracked even though my machines carry the administrator's "ignore" cookie. Any easy way to address this glitch? Thanks.
The text was updated successfully, but these errors were encountered: