New issue
Advanced search Search tips

Issue 739787 link

Starred by 3 users

Issue metadata

Status: Fixed
Owner:
Closed: Apr 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Android , Windows , Chrome , Mac , Fuchsia
Pri: 3
Type: Bug



Sign in to add a comment

iframe.sandbox.supports() does not recognize 3 tokens that are actually supported

Project Member Reported by loonyb...@chromium.org, Jul 6 2017

Issue description

DOMTokenList validator for the sandbox attribute (https://cs.chromium.org/chromium/src/third_party/WebKit/Source/core/html/HTMLIFrameElementSandbox.cpp) is missing allow-orientation-lock, allow-presentation, and allow-top-navigation-by-user-activation.

They are not recognized by iframe.sandbox.supports() but are actually supported. 

Is there a reason behind it?

Thanks
 
Cc: iclell...@chromium.org
Do you have any updates for this?

I faced issue that iframe.sandbox.supports('allow-top-navigation-by-user-activation') returns false. It is bad behavior.

Comment 3 by pasta0...@gmail.com, Apr 10 2018

I found commit to fix https://chromium.googlesource.com/chromium/src/+/aa16224b6dd03cf35c5167cc5a2ce11b533b63b1 and works on current Beta. Thanks
Status: Available (was: Untriaged)
Thanks -- it looks like the other two are still missing; those should get fixed.
Components: -Internals>Sandbox Blink>SecurityFeature>IFrameSandbox
Labels: OS-Android OS-Chrome OS-Fuchsia OS-Linux OS-Mac OS-Windows
Owner: iclell...@chromium.org
Status: Started (was: Available)
Project Member

Comment 6 by bugdroid1@chromium.org, Apr 13 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/763d8cc7561615b7c3f7bdea8de2d4521c104781

commit 763d8cc7561615b7c3f7bdea8de2d4521c104781
Author: Ian Clelland <iclelland@chromium.org>
Date: Fri Apr 13 17:42:20 2018

Fix the set of sandbox tokens recognized by iframe.sandbox.supports()

Two tokens were missing from the list: allow-orientation-lock and
allow-presentation. In addition, allow-downloads was reported as being
supported, when it actually depends on a runtime flag which is off by
default.

Bug:  739787 
Change-Id: Iadea9ebf45c7c0b63e8775f5c10aaa0c764a6807
Reviewed-on: https://chromium-review.googlesource.com/1005414
Commit-Queue: Ian Clelland <iclelland@chromium.org>
Reviewed-by: Mike West <mkwst@chromium.org>
Cr-Commit-Position: refs/heads/master@{#550673}
[modify] https://crrev.com/763d8cc7561615b7c3f7bdea8de2d4521c104781/third_party/WebKit/LayoutTests/fast/dom/HTMLIFrameElement/sandbox-feature-detection.html
[modify] https://crrev.com/763d8cc7561615b7c3f7bdea8de2d4521c104781/third_party/blink/renderer/core/html/html_iframe_element_sandbox.cc

Status: Fixed (was: Started)
Project Member

Comment 8 by bugdroid1@chromium.org, Apr 17 2018

Labels: merge-merged-testbranch
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/763d8cc7561615b7c3f7bdea8de2d4521c104781

commit 763d8cc7561615b7c3f7bdea8de2d4521c104781
Author: Ian Clelland <iclelland@chromium.org>
Date: Fri Apr 13 17:42:20 2018

Fix the set of sandbox tokens recognized by iframe.sandbox.supports()

Two tokens were missing from the list: allow-orientation-lock and
allow-presentation. In addition, allow-downloads was reported as being
supported, when it actually depends on a runtime flag which is off by
default.

Bug:  739787 
Change-Id: Iadea9ebf45c7c0b63e8775f5c10aaa0c764a6807
Reviewed-on: https://chromium-review.googlesource.com/1005414
Commit-Queue: Ian Clelland <iclelland@chromium.org>
Reviewed-by: Mike West <mkwst@chromium.org>
Cr-Commit-Position: refs/heads/master@{#550673}
[modify] https://crrev.com/763d8cc7561615b7c3f7bdea8de2d4521c104781/third_party/WebKit/LayoutTests/fast/dom/HTMLIFrameElement/sandbox-feature-detection.html
[modify] https://crrev.com/763d8cc7561615b7c3f7bdea8de2d4521c104781/third_party/blink/renderer/core/html/html_iframe_element_sandbox.cc

Sign in to add a comment