New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 665381 link

Starred by 3 users

Issue metadata

Status: Untriaged
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug-Regression



Sign in to add a comment

Chrome HBD (HTML BY DEFAULT) - Issue with navigator.plugins while modifying site-engagement

Reported by mbi...@zynga.com, Nov 15 2016

Issue description

UserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_4) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.44 Safari/537.36

Steps to reproduce the problem:
Example URL:
https://apps.facebook.com/farmville-two/

Prerequisites:

1. Download chrome 55 beta version.
2. Goto chrome://site-engagement and modify site engagement score of apps.facebook.com to a value less than 30
3. Make sure "prefer HTML by default" is enabled in chrome://flags
4. Goto chrome settings, search for flash content settings and ensure flash setting is "Ask first before allowing sites to run Flash (Recommended). Also ensure no exceptions are made to apps.facebook.com/farmville-two

Steps:
1) Goto apps.facebook.com/farmville-two
2) Goto Developer tools -> console and type navigator.plugins['Shockwave Flash'] and click enter

What is the expected behavior?

What went wrong?
In above scenario two results are shown

1) Most of the times navigator.plugins['Shockwave Flash'] is undefined. This is happening 90% of the times

2) In some cases, navigator.plugins['Shockwave Flash'] contains the expected element (Shockwave flash)

I assume above property is changed by based on site-engagement score of the browser for HBD feature in chrome 55.
We want a consistent behavior as we use 'navigator.plugin' to embed flash content or not. Also our flash detection logic is based on it. 

Due to this inconsistency, we are unable to have a foolproof of flash block by chrome and also embedding game swf is affected.

Did this work before? Yes Chrome 54 - navigator.plugin always used to hold 'Shockwave Flash' element

Chrome version: 55.0.2883.44  Channel: beta
OS Version: OS X 10.10.4
Flash Version:
 

Comment 1 by phistuck@gmail.com, Nov 15 2016

My guess is that Chrome increases the site engagement score as a result of you interacting with the website.
1. When the object is returned, go to chrome://site-engagement - is it still below 30?
2. When the object is returned, is Flash still blocked?

Comment 2 by mbi...@zynga.com, Nov 15 2016

PFB replies

1) We know chrome increases site engagement. But we went and explicitly changed it to less than 30. When object was returned, we checked site-engagement it was less than 30. We checked with values like 8 and 25, 28, etc. 

2) When object is returned, chrome displayed a grey clickable screen. So flash is still blocked by chrome and our game didn't load.

Above issue happened during 12 to 1 PM IST today. 
After that we're unable to reproduce. Chrome is not having that object when flash is blocked.

Comment 3 by mbi...@zynga.com, Nov 15 2016

Hi Phistuck,

We've got the exact reproduction steps for above issue. Above issue is happening once site engagement goes above 30 and we manually reset it to a value less than 30. At that point in time, if you check for navigator.plugins it contains 'shockwave flash' object, but flash is blocked by chrome

If you restart chrome, navigator.plugins is getting reset and doesn't contain shockwave flash object.

We tried using navigator.mimetypes also, but same behavior is happening for that property too.

Please help us with below two questions.
1) Is this issue with modifying site-engagement score? 
2) I know site engagement score increases with each visit. But let's say, I didn't visit a particular site for long time. Will my previous site engagement go down?

Exact steps to reproduce:

1) Take a flash website, goto site-engagement and modify to a score less than 30 (say 25).
2) Visit the site multiple times and check for navigator.plugins or navigator.mimeTypes to contain 'shockwave flash' object. It won't contain the object.
3) Visit the site multiple times, so that site-engagement score becomes greater than 30
4) At this point, goto the same flash site, check for navigator.plugin or navigator.mimeTypes. Both will contain 'shockwave flash' object. But Flash would be blocked by chrome.
5) Now restart chrome without any changes. Goto same flash site, navigator.plugins or navigator.mimeTypes would not contain 'shockwave flash'

Expected behavior:
Whenever flash is blocked by chrome, navigator.plugin or navigator.mimeTypes should not contain 'shockwave flash' object.


Comment 4 by phistuck@gmail.com, Nov 15 2016

Step 5 seems a bit unexpected as well, since the site engagement score at this point is larger than 30 (see step 3), but Flash still does not exist.

Comment 5 by mbi...@zynga.com, Nov 15 2016

Oops. My bad! missed a step. Below is correct steps.

Exact steps to reproduce:

1) Take a flash website, goto site-engagement and modify to a score less than 30 (say 25).
2) Visit the site multiple times and check for navigator.plugins or navigator.mimeTypes to contain 'shockwave flash' object. It won't contain the object.
3) Visit the site multiple times, so that site-engagement score becomes greater than 30
4) Now goto site-engagement and manually change the score to a value lesser than 30.
5) At this point, goto the same flash site, check for navigator.plugin or navigator.mimeTypes. Both will contain 'shockwave flash' object. But Flash would be blocked by chrome.
6) Now restart chrome without any changes. Goto same flash site, navigator.plugins or navigator.mimeTypes would not contain 'shockwave flash'
Components: -Blink Internals>Plugins>Flash>PreferHTML5
Cc: pbomm...@chromium.org lafo...@chromium.org ericde@chromium.org
Labels: M-55 ReleaseBlock-Stable
I am trying to reproduce the bug, but added stable blocker for now.
Cc: tommycli@chromium.org raymes@chromium.org
Labels: -M-55 -ReleaseBlock-Stable M-56
Removing the release block label.  Agreed that this is an odd state that we should look into, however given that manual manipulation of the site engagement score is required to reproduce this issue, it likely isn't a common case that most users would discover (be able to discover to do).
Status: Untriaged (was: Unconfirmed)
Tested the same on mac 10.11.6 chrome version 56.0.2924.3 - navigator.plugins['Shockwave Flash']  in console displays undefined

Confirming the issue for further inputs on this
Labels: -Pri-2 Pri-3
Cc: dominickn@chromium.org
Hey - Dom, Raymes, and I are aware of the inconsistent behavior that can occur when site engagement changes.

We've discussed the possibility of making the SEI score 'sticky' per navigation, but none of us have considered it a high enough priority to actually implement this. And until this bug report, no one had actually hit this edge case in the wild.

In all cases, I believe navigator.plugins reflects the actual state of the plugin list. If the SEI score increases, and Flash then appears in navigator.plugins, subsequent attempts to instantiate a Flash object will succeed (not be blocked).
Labels: -OS-Mac

Sign in to add a comment