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

detecting java plugin on edge browser? #12117

Closed
pavarnos opened this issue Sep 25, 2017 · 18 comments · Fixed by #12214
Closed

detecting java plugin on edge browser? #12117

pavarnos opened this issue Sep 25, 2017 · 18 comments · Fixed by #12214
Assignees
Labels
duplicate For issues that already existed in our issue tracker and were reported previously.

Comments

@pavarnos
Copy link

Hi. Piwik appears to detect Java and PDF plugins for MS Edge, but Edge does not allow plugins?

screen_shot_2017-09-26_at_12_09_34_pm

@Findus23
Copy link
Member

Hi, can you enter navigator.mimetypes into the JavaScript console and paste the result here?
Piwik is checking for application/x-java-vm and application/pdf

See also here: https://github.com/piwik/piwik/blob/3.x-dev/js/piwik.js#L5423

@sgiehl
Copy link
Member

sgiehl commented Sep 27, 2017

Had a short look at an Edge browser. It seems to have an built in PDF viewer, and maybe it automatically uses JAVA if installed.
Maybe at some point we shouldn't name it "Plugins" anymore, as it more or less represents supported "technologies" and not real plugins anymore...

@Findus23
Copy link
Member

Maybe at some point we shouldn't name it "Plugins" anymore, as it more or less represents supported "technologies" and not real plugins anymore...

I agree. See also: https://forum.piwik.org/t/cookie-browser-plugin/25711

@pavarnos
Copy link
Author

pavarnos commented Sep 27, 2017

sorry for the delay: my user is in a time zone 13 hours different to mine. Takes a while to arrange a meeting... his navigator.mimetypes below. I just checked a more recent login and it is still showing the same as the original image above. Perhaps piwik is aggregating / collating across many different sessions (from different devices) instead of showing the plugins just from the current (most recent) session / device?
edge_navigator_mimetypes

@mattab
Copy link
Member

mattab commented Sep 27, 2017

Perhaps piwik is aggregating / collating across many different sessions (from different devices)

That would be the case only if you use User ID https://piwik.org/docs/user-id/ and if user connected from different devices with the same user id

@pavarnos
Copy link
Author

pavarnos commented Sep 27, 2017

Yes, we are using a consistent UserId across all devices: every user must log in. So we know who they are. Is there a way to configure piwik to only record the plugins from the most recent few visits? (say 2 or 3 visits?)

@pavarnos
Copy link
Author

pavarnos commented Sep 27, 2017

Looking at the source code, there is separate java detection https://github.com/piwik/piwik/blob/3.x-dev/js/piwik.js#L5459. So i asked him to type navigator.javaEnabled() in his browser. Result is true. He recently ran the Java removal tool from oracle, so hopefully it is gone from his computer? Odd that Edge (which supports no plugins) has this returning true?

@pavarnos
Copy link
Author

https://html.spec.whatwg.org/multipage/system-state.html#dom-navigator-javaenabled

The navigator.javaEnabled() method must return true if the user agent supports a plugin that supports the MIME type "application/x-java-vm"; otherwise it must return false.

@pavarnos
Copy link
Author

pavarnos commented Oct 17, 2017

How does piwik aggregate browser plugins cross different visitor sessions (with UserId enabled)? Is it the last N sessions? All detected plugins for all time?
Are there any configuration settings to change this?

I'm using Piwik to understand what browser plugins our users have installed. Then I can go visit each user and say "hey, you should really disable Flash". But I need to know what the user had enabled on their last visit (or 2)... Is this possible?

@mattab
Copy link
Member

mattab commented Oct 17, 2017

How does piwik aggregate browser plugins cross different visitor sessions (with UserId enabled)? Is it the last N sessions? All detected plugins for all time? Are there any configuration settings to change this?

The plugin detection is done once per visit. so each "Session" (ie. visit) will have their own set of plugins.

@pavarnos
Copy link
Author

@mattab thanks for the quick reply. The visitor profile shows the plugin info only at the top of the page. Is this for the most recent visit? Or is it some aggregation of all the visits?

I'm trying to figure out why an Edge user is shown as having a Java plugin enabled when Java has been removed from his computer (in the last few weeks) and Edge does not support plugins (eg Java).

@mattab
Copy link
Member

mattab commented Oct 17, 2017

Are you using latest Piwik version? in the latest version you can see plugins for each individual visit by clicking on the visit row itself

@pavarnos
Copy link
Author

Piwik version 3.2.0.
Thanks: I did not know that about plugins for each visit. Very handy to have the extra detail.

So here is a visit from the same user 10 days ago, using Edge, which shows the Java plugin. See the screenshots above which show Java is not installed. So why is it showing Java?
screen_shot_2017-10-17_at_8_50_32_pm

@mattab
Copy link
Member

mattab commented Oct 17, 2017

using Edge, which shows the Java plugin. See the screenshots above which show Java is not installed. So why is it showing Java?

No idea about that

@sgiehl
Copy link
Member

sgiehl commented Oct 19, 2017

It's right that Edge dropped support for any plugin. But there could be another reason for this "incorrect" data. The browser plugins are detected using javascript, whereas the browser itself is detected by parsing the user agent. Actually someone could use firefox with an extension to change the useragent. That way Piwik would detect the plugins the firefox has, but would be reported as another browser according to the useragent.

@pavarnos
Copy link
Author

pavarnos commented Oct 19, 2017

@sgiehl fair point. In this specific case I observed the user open Edge. He has no reason to fake his user agent (and probably doesn't know how). We took the console screenshots above from his screen. We have many similar Edge users with piwik reporting Java (and Flash in some cases). Anything I can do to help diagnose this?

@sgiehl
Copy link
Member

sgiehl commented Oct 20, 2017

@pavarnos On my Edge navigator.javaEnabled() returns true as well, which imho it shouldn't. so maybe we shouldn't check that on Edge. Will prepare a PR for that.

@pavarnos
Copy link
Author

pavarnos commented Oct 20, 2017 via email

@mattab mattab added the duplicate For issues that already existed in our issue tracker and were reported previously. label Dec 5, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate For issues that already existed in our issue tracker and were reported previously.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants