New issue
Advanced search Search tips

Issue 728103 link

Starred by 4 users

Issue metadata

Status: Assigned
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux
Pri: 3
Type: Feature



Sign in to add a comment

Video fullscreen fails without user interaction in kiosk mode

Reported by goo...@systemstart.net, May 31 2017

Issue description

UserAgent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/60.0.3080.5 Chrome/60.0.3080.5 Safari/537.36

Steps to reproduce the problem:
1. open attached html in kiosk mode: chromium --kiosk test_fullscreen.html 

What is the expected behavior?
after one second the </div> should go fullscreen

What went wrong?
browser refuses fullscreen request: "test_fullscreen.html:12 Failed to execute 'requestFullscreen' on 'Element': API can only be initiated by a user gesture."

from the error handler:
webkitfullscreenerror: {"isTrusted":true}

Did this work before? N/A 

Does this work in other browsers? N/A

Chrome version: 60.0.3080.5  Channel: n/a
OS Version: 
Flash Version: 

a kiosk site should be trusted enough to deactivate the security measurement requiring the user gesture.
 
test_fullscreen.html
581 bytes View Download
Components: Blink>Input Blink>SecurityFeature UI>Shell>Kiosk

Comment 2 by bokan@chromium.org, Jun 1 2017

Cc: bokan@chromium.org mustaq@chromium.org rbyers@chromium.org
Labels: -Type-Bug -Pri-2 Hotlist-Input-Dev Pri-3 Type-Feature
Status: Untriaged (was: Unconfirmed)
This sounds reasonable to me but I don't know enough about how we view kiosk mode. +rbyers@ and +mustaq@ who have/are looking at user gesture indicators. Is this something we'd consider relaxing?
Owner: mustaq@chromium.org
Status: Assigned (was: Untriaged)
Hmm, I would have expected kiosk mode chrome in full-screen w/o a requestFullscreen call!  So my first thought is that this is not a gesture-related problem.

Clarification questions:
- Do we expect multiple windows in the mode?
- Or even multiple tabs?


my problem is not the browser itself in fullscreen mode(which works fine) but one specific dom-node in fullscreen mode, for example a <video> tag.

i'm using a single tab in kiosk mode, the user has no options to navigate between tabs. 

i think this is the more common usecase.
Owner: mlamouri@chromium.org
Summary: Video fullscreen fails without user interaction in kiosk mode (was: element to fullscreen without user interaction in kiosk mode)
So the problem is that you can't play a fullscreen video w/o a gesture, right?  Then the test page above doesn't apply.

Could you please create a minimal test for this?

mlamouri@: Looks like it's your domain?
Cc: foolip@chromium.org
Owner: mustaq@chromium.org
Re-assigning to you mustaq@.

Indeed, OP is trying to make <video> fullscreen but this is using the Fullscreen API which requires a user gesture.

Maybe we could use a similar system as the autoplay whitelist from Web APK with kiosk mode? That whitelist could apply to fullscreen?

+foolip@ as it is fullscreen related.
i don't see a different behaviour trying to switch a <div> to fullscreen or a <video> to fullscreen.

both fails when there was no user gesture, both fails with the same error.

i think the attached example is minimal, you want me to do s/div/video/g and attach a new example? 
google@systemstart.net: your repro is fine since it repros.

foolip@: Can we whitelist the Fullscreen API with kiosk mode as Mounir suggested?

I don't know what kiosk mode is, but if Chromium is used to render non-web content that is entirely under the control of the kiosk maintainer, the bypassing the user gesture checks seems fine. Note that this is not really a security check, but a user annoyance mitigation.

Note that if the same configuration is ever used to browser the web, that might be a problem, because there may well be requestFullscreen() calls out there copy-pasted and forgotten that have never worked, that then start going fullscreen where it actually was not intended.
hi.

i take from this discussion that a fix seems legit.

as i am working for a company which would use this feature, a donation 
or bounty would be possible, if the outcome would be a patch or fixed 
version.

cheers,

alexander

On 07.06.2017 15:25, foo… via monorail wrote:

Comment 11 by phistuck@gmail.com, Aug 31 2017

#9 - what about an even simpler logic? If the document is already in full screen mode (be it due to kiosk mode or due to already calling requestFullscreen with a user gesture beforehand), let any call to requestFullscreen pass without a user gesture.

It should not matter to the user whether the page brings an element to the full screen or stays full screen with the entire document and the page can do it in other ways (hiding everything else from the page using JavaScript and put the element forward instead), so you are not preventing anything anyway.
#11, I think something like that could make sense, at least if the element's node document is already fullscreen. (An iframe inside a document that happens to be fullscreen should probably not be exempted.) Then there's the question about how to detect kiosk mode, which I don't know anything about, but it could reasonably behave as if the top-level document is fullscreen.
Labels: UserActivation
Labels: Hotlist-EnamelAndFriendsFixIt
Components: Blink>Media>Autoplay
Labels: -Hotlist-EnamelAndFriendsFixIt
Components: -Blink>Media>Autoplay

Sign in to add a comment