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

Issue 2880713002: Support combination of [OriginTrialEnabled] and [SecureContext] (Closed)

Created:
3 years, 7 months ago by chasej
Modified:
3 years, 7 months ago
Reviewers:
haraken, iclelland, Yuki
CC:
chromium-reviews, iclelland+watch_chromuim.org, blink-reviews, haraken, blink-reviews-bindings_chromium.org, chasej+watch_chromium.org
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

Support combination of [OriginTrialEnabled] and [SecureContext] This CL fixes the bindings logic to allow the [OriginTrialEnabled] and [SecureContext] to be used together on the same IDL members. The bug was found when trying to use [SecureContext] for WebUSB. The IDL definition for WebUSB is corrected to use [SecureContext] as well. Other cleanups in this CL: - Remove unused check_origin_trial macro - Remove obsolete attribute variable, and fix reference for generating include - Apply some consistency to attribute and method helper functions BUG=695123 Review-Url: https://codereview.chromium.org/2880713002 Cr-Commit-Position: refs/heads/master@{#472062} Committed: https://chromium.googlesource.com/chromium/src/+/3326804ff57fe560d03b1d6b740c272c01082bfe

Patch Set 1 #

Patch Set 2 : Remove workarounds #

Total comments: 19

Patch Set 3 : Address comments and some cleanup #

Patch Set 4 : Revert back to a partial workaround for WebUSB #

Patch Set 5 : Rebase #

Unified diffs Side-by-side diffs Delta from patch set Stats (+77 lines, -101 lines) Patch
M third_party/WebKit/LayoutTests/http/tests/origin_trials/resources/origintrials.js View 1 chunk +3 lines, -8 lines 0 comments Download
M third_party/WebKit/Source/bindings/modules/v8/ConditionalFeaturesForModules.cpp View 1 2 3 2 chunks +2 lines, -8 lines 0 comments Download
M third_party/WebKit/Source/bindings/scripts/code_generator.py View 1 2 2 chunks +3 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/bindings/scripts/v8_attributes.py View 1 2 2 chunks +7 lines, -6 lines 0 comments Download
M third_party/WebKit/Source/bindings/scripts/v8_interface.py View 1 2 5 chunks +17 lines, -12 lines 0 comments Download
M third_party/WebKit/Source/bindings/scripts/v8_methods.py View 1 2 3 chunks +14 lines, -9 lines 0 comments Download
M third_party/WebKit/Source/bindings/scripts/v8_utilities.py View 3 chunks +1 line, -8 lines 0 comments Download
M third_party/WebKit/Source/bindings/templates/attributes.cpp.tmpl View 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/bindings/templates/interface.h.tmpl View 1 2 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/bindings/templates/interface_base.cpp.tmpl View 1 2 5 chunks +10 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/bindings/templates/methods.cpp.tmpl View 2 chunks +1 line, -3 lines 0 comments Download
M third_party/WebKit/Source/bindings/templates/partial_interface.h.tmpl View 1 2 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/bindings/templates/utilities.cpp.tmpl View 1 chunk +0 lines, -13 lines 0 comments Download
M third_party/WebKit/Source/bindings/tests/results/core/V8TestConstants.h View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M third_party/WebKit/Source/core/testing/OriginTrialsTest.idl View 1 chunk +9 lines, -12 lines 0 comments Download
M third_party/WebKit/Source/core/testing/OriginTrialsTestPartial.idl View 1 chunk +4 lines, -6 lines 0 comments Download
M third_party/WebKit/Source/modules/installedapp/NavigatorInstalledApp.idl View 1 1 chunk +1 line, -5 lines 0 comments Download
M third_party/WebKit/Source/modules/webusb/NavigatorUSB.idl View 1 chunk +1 line, -4 lines 0 comments Download

Messages

Total messages: 38 (28 generated)
chasej
iclelland, please take a look.
3 years, 7 months ago (2017-05-12 04:13:35 UTC) #5
Yuki
Overall, l-g-t-m. Defer to iclelland@. https://codereview.chromium.org/2880713002/diff/20001/third_party/WebKit/Source/bindings/scripts/code_generator.py File third_party/WebKit/Source/bindings/scripts/code_generator.py (right): https://codereview.chromium.org/2880713002/diff/20001/third_party/WebKit/Source/bindings/scripts/code_generator.py#newcode67 third_party/WebKit/Source/bindings/scripts/code_generator.py:67: def secure_context_cached_if(code, secure_context_test): Hmm, ...
3 years, 7 months ago (2017-05-12 09:10:05 UTC) #11
haraken
LGTM https://codereview.chromium.org/2880713002/diff/20001/third_party/WebKit/Source/bindings/scripts/v8_interface.py File third_party/WebKit/Source/bindings/scripts/v8_interface.py (right): https://codereview.chromium.org/2880713002/diff/20001/third_party/WebKit/Source/bindings/scripts/v8_interface.py#newcode159 third_party/WebKit/Source/bindings/scripts/v8_interface.py:159: not attribute['origin_trial_feature_name'])] Can we create a helper function ...
3 years, 7 months ago (2017-05-12 11:05:54 UTC) #13
Yuki
https://codereview.chromium.org/2880713002/diff/20001/third_party/WebKit/Source/bindings/scripts/v8_interface.py File third_party/WebKit/Source/bindings/scripts/v8_interface.py (right): https://codereview.chromium.org/2880713002/diff/20001/third_party/WebKit/Source/bindings/scripts/v8_interface.py#newcode415 third_party/WebKit/Source/bindings/scripts/v8_interface.py:415: method for method in conditional_enabled_methods) On 2017/05/12 11:05:54, haraken ...
3 years, 7 months ago (2017-05-12 14:04:25 UTC) #14
iclelland
Python style nits aside, this looks good from an origin trials perspective. It looks like ...
3 years, 7 months ago (2017-05-12 15:11:49 UTC) #15
Yuki
https://codereview.chromium.org/2880713002/diff/20001/third_party/WebKit/Source/bindings/scripts/code_generator.py File third_party/WebKit/Source/bindings/scripts/code_generator.py (right): https://codereview.chromium.org/2880713002/diff/20001/third_party/WebKit/Source/bindings/scripts/code_generator.py#newcode70 third_party/WebKit/Source/bindings/scripts/code_generator.py:70: return generate_indented_conditional(code, 'isSecureContext') On 2017/05/12 15:11:49, iclelland wrote: > ...
3 years, 7 months ago (2017-05-12 15:14:12 UTC) #16
chasej
iclelland, please take another look. The external wpt test for WebUSB was failing after removing ...
3 years, 7 months ago (2017-05-16 02:21:40 UTC) #27
iclelland
LGTM -- can you update either crbug.com/695123 or crbug.com/691031 (whichever is appropriate) with a note ...
3 years, 7 months ago (2017-05-16 03:55:08 UTC) #28
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/2880713002/80001
3 years, 7 months ago (2017-05-16 11:42:17 UTC) #35
commit-bot: I haz the power
3 years, 7 months ago (2017-05-16 11:46:55 UTC) #38
Message was sent while issue was closed.
Committed patchset #5 (id:80001) as
https://chromium.googlesource.com/chromium/src/+/3326804ff57fe560d03b1d6b740c...

Powered by Google App Engine
This is Rietveld 408576698