Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(36)

Issue 2767983003: Initial Implementation of Iframe Attribute for Feature Policy (Part 4) (Closed)

Created:
3 years, 9 months ago by lunalu1
Modified:
3 years, 7 months ago
Reviewers:
haraken, iclelland
CC:
lunalu1, blink-reviews, blink-reviews-dom_chromium.org, chromium-reviews, dcheng, dglazkov+blink, eae+blinkwatch, gogerald+paymentswatch_chromium.org, iclelland, kinuko+watch, mahmadi+paymentswatch_chromium.org, mlamouri+watch-blink_chromium.org, rwlbuis, rouslan+payments_chromium.org, sebsg+paymentswatch_chromium.org, sof
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

Initial Implementation of Iframe Attribute for Feature Policy (Part 4) Replace implementation of allowpaymentrequest and allowfullscreen by feature policy. Enable iframe feature policy by attributes: allow="feature1 feature2", allowfullscreen, and allowpaymentrequest. See design doc: https://docs.google.com/a/chromium.org/document/d/1sskoBi7Ba7hLuuiJQ6VMQ1KYIGBP8Lr87hLbkF76c2I/edit?usp=sharing Part 1: Introduce iframe allowAttr in HTMLIFrameElement::parseAttribute and store featureNames in HTMLIFrameElement (CL: https://codereview.chromium.org/2680083002/) Part 2: Propagate featureNames from HTMLIFrameElement to frame owner and remote frame owner. (CL: https://codereview.chromium.org/2697713003) Part 3: Set iframe feature policy in FrameLoader::didBeginDocument 3.a Replace string by enum in WebParsedFeaturePolicyDeclaration#feature (CL: https://codereview.chromium.org/2727803004/) 3.b Rename WebParsedFeaturePolicyHeader to WebParsedFeaturePolicy (CL: https://codereview.chromium.org/2738953002/) Part 4: Replace implementation of allowpaymentrequest and allowfullscreen by feature policy. BUG=682256 Review-Url: https://codereview.chromium.org/2767983003 Cr-Commit-Position: refs/heads/master@{#467699} Committed: https://chromium.googlesource.com/chromium/src/+/44b442a4f245e3fbfa17478bf0807cc139ab39ef

Patch Set 1 : Initial Impl. TODO: add more layout tests for allow attribute #

Patch Set 2 : Added layout tests for container policy (w/ & w/o relocation) #

Patch Set 3 : Nit #

Total comments: 4

Patch Set 4 : Updated implementation after rebase (TODO: add tests for vibrate after 2814153002 is landed #

Patch Set 5 : Added container policy tests for vibrate #

Total comments: 6

Patch Set 6 : Codereview: nit + added more unit tests for container policy #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+511 lines, -68 lines) Patch
A third_party/WebKit/LayoutTests/http/tests/feature-policy-experimental-features/resources/feature-policy-vibrate-relocate.html View 1 2 3 4 1 chunk +15 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/http/tests/feature-policy-experimental-features/vibrate-allowed-by-container-policy.html View 1 2 3 4 1 chunk +26 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/http/tests/feature-policy-experimental-features/vibrate-allowed-by-container-policy-relocate.html View 1 2 3 4 1 chunk +37 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/http/tests/feature-policy/fullscreen-allowed-by-container-policy.html View 1 1 chunk +32 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/http/tests/feature-policy/fullscreen-allowed-by-container-policy-expected.txt View 1 2 3 1 chunk +7 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/http/tests/feature-policy/fullscreen-allowed-by-container-policy-relocate.html View 1 1 chunk +44 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/http/tests/feature-policy/fullscreen-allowed-by-container-policy-relocate-expected.txt View 1 2 3 1 chunk +9 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/http/tests/feature-policy/payment-allowed-by-container-policy.html View 1 1 chunk +13 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/http/tests/feature-policy/payment-allowed-by-container-policy-expected.txt View 1 2 3 1 chunk +33 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/http/tests/feature-policy/payment-allowed-by-container-policy-relocate.html View 1 1 chunk +20 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/http/tests/feature-policy/payment-allowed-by-container-policy-relocate-expected.txt View 1 2 3 1 chunk +49 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/http/tests/feature-policy/resources/feature-policy-fullscreen-relocate.html View 1 1 chunk +16 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/http/tests/feature-policy/resources/feature-policy-payment-relocate-disabled.html View 1 2 1 chunk +7 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/http/tests/feature-policy/resources/feature-policy-payment-relocate-enabled.html View 1 2 1 chunk +7 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/virtual/feature-policy/http/tests/feature-policy/fullscreen-allowed-by-container-policy-expected.txt View 1 2 3 1 chunk +7 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/virtual/feature-policy/http/tests/feature-policy/fullscreen-allowed-by-container-policy-relocate-expected.txt View 1 2 3 1 chunk +9 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/virtual/feature-policy/http/tests/feature-policy/payment-allowed-by-container-policy-expected.txt View 1 2 3 1 chunk +33 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/virtual/feature-policy/http/tests/feature-policy/payment-allowed-by-container-policy-relocate-expected.txt View 1 2 3 1 chunk +49 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/dom/Fullscreen.cpp View 1 2 3 1 chunk +3 lines, -29 lines 0 comments Download
M third_party/WebKit/Source/core/html/HTMLFrameOwnerElement.cpp View 1 2 3 2 chunks +4 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/modules/payments/PaymentRequest.cpp View 1 2 3 4 5 1 chunk +2 lines, -31 lines 0 comments Download
M third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.h View 1 2 3 4 1 chunk +2 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp View 1 2 3 4 5 5 chunks +35 lines, -5 lines 2 comments Download
M third_party/WebKit/Source/platform/feature_policy/FeaturePolicyTest.cpp View 1 2 3 4 5 3 chunks +50 lines, -1 line 0 comments Download
M third_party/WebKit/Source/web/WebRemoteFrameImpl.cpp View 1 2 3 5 1 chunk +2 lines, -0 lines 0 comments Download

Dependent Patchsets:

Messages

Total messages: 50 (37 generated)
lunalu1
Hi Ian, I added some layout tests for container policy in this patch too. Please ...
3 years, 8 months ago (2017-03-28 15:58:11 UTC) #12
iclelland
Since the great blink rename, you'll need to update this to follow the new style. ...
3 years, 8 months ago (2017-04-11 19:04:21 UTC) #22
lunalu1
Hi Ian. I added container policy tests for vibrate and made changes based on your ...
3 years, 8 months ago (2017-04-24 20:24:21 UTC) #28
iclelland
This is looking great, thanks! Just a couple of comments. https://codereview.chromium.org/2767983003/diff/120001/third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp File third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp (right): https://codereview.chromium.org/2767983003/diff/120001/third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp#newcode84 ...
3 years, 8 months ago (2017-04-25 17:19:55 UTC) #32
lunalu1
Thanks Ian. PTAL
3 years, 8 months ago (2017-04-25 17:55:47 UTC) #33
lunalu1
Hi Ian, Sorry I missed some of your comments. Please review this patch instead. https://codereview.chromium.org/2767983003/diff/120001/third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp ...
3 years, 8 months ago (2017-04-25 18:31:42 UTC) #36
iclelland
Thanks for the update! This LGTM
3 years, 8 months ago (2017-04-25 18:38:05 UTC) #38
lunalu1
Hi haraken, could you please owner approve this CL? Files to be reviewed: third_party/WebKit/Source/core/dom/Fullscreen.cpp third_party/WebKit/Source/core/html/HTMLFrameOwnerElement.cpp ...
3 years, 8 months ago (2017-04-25 21:10:42 UTC) #42
haraken
https://codereview.chromium.org/2767983003/diff/160001/third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp File third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp (right): https://codereview.chromium.org/2767983003/diff/160001/third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp#newcode103 third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp:103: bool allowpayment, This looks a bit too ad-hoc to ...
3 years, 8 months ago (2017-04-26 02:34:34 UTC) #43
iclelland
https://codereview.chromium.org/2767983003/diff/160001/third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp File third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp (right): https://codereview.chromium.org/2767983003/diff/160001/third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp#newcode103 third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp:103: bool allowpayment, On 2017/04/26 02:34:34, haraken wrote: > > ...
3 years, 8 months ago (2017-04-26 02:59:47 UTC) #44
haraken
On 2017/04/26 02:59:47, iclelland wrote: > https://codereview.chromium.org/2767983003/diff/160001/third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp > File third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp > (right): > > https://codereview.chromium.org/2767983003/diff/160001/third_party/WebKit/Source/platform/feature_policy/FeaturePolicy.cpp#newcode103 ...
3 years, 8 months ago (2017-04-26 03:07:35 UTC) #45
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2767983003/160001
3 years, 7 months ago (2017-04-27 14:03:33 UTC) #47
commit-bot: I haz the power
3 years, 7 months ago (2017-04-27 16:11:11 UTC) #50
Message was sent while issue was closed.
Committed patchset #6 (id:160001) as
https://chromium.googlesource.com/chromium/src/+/44b442a4f245e3fbfa17478bf080...

Powered by Google App Engine
This is Rietveld 408576698