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

Issue 1908263002: Don't expose URL.createObjectURL and revokeObjectURL to Service Workers (Closed)

Created:
4 years, 8 months ago by jsbell
Modified:
4 years, 7 months ago
CC:
chromium-reviews, kenjibaheux+watch_chromium.org, tzik, eae+blinkwatch, eric.carlson_apple.com, rwlbuis, jsbell+serviceworker_chromium.org, blink-reviews-dom_chromium.org, dglazkov+blink, blink-reviews-bindings_chromium.org, blink-reviews, mcasas+watch+mediastream_chromium.org, philipj_slow, sof, nhiroki, feature-media-reviews_chromium.org, tommyw+watchlist_chromium.org, michaeln, mlamouri+watch-blink_chromium.org, serviceworker-reviews, kinuko+serviceworker, horo+watch_chromium.org, kinuko+fileapi
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Don't expose URL.createObjectURL and revokeObjectURL to Service Workers Per FileAPI[1] which was updated based on Service Worker discussion[2], minting blob URLs should not be possible within SWs. A bug has been filed against MediaSource[3] to update the IDL there (following the same logic), and mediastream's createObjectURL is no longer present in the standard. Regardless, the overloads should never execute in Service Workers as those types (MediaStream, MediaSource) are not exposed in that context. Note that the [Exposed] attributes are applied directly to the interface members as they appear to be ignored on the partial interface. (Bug?) [1] https://w3c.github.io/FileAPI/#creating-revoking [2] https://github.com/slightlyoff/ServiceWorker/issues/688 [3] https://github.com/w3c/media-source/issues/67 Intent Thread: https://groups.google.com/a/chromium.org/d/msg/blink-dev/HuA7Ng9U0oc/CYvfMoeyBwAJ BUG=604951, 608460 Committed: https://crrev.com/9e232c512c962a7aecc85e07f7a48a4735dc7a25 Cr-Commit-Position: refs/heads/master@{#393271}

Patch Set 1 #

Total comments: 4

Patch Set 2 : review nits #

Patch Set 3 : Rebased on refactor-only CL #

Patch Set 4 : Remove deprecations #

Patch Set 5 : Update expectations/update fetch tests #

Total comments: 12

Patch Set 6 : test cleanup #

Unified diffs Side-by-side diffs Delta from patch set Stats (+57 lines, -78 lines) Patch
M third_party/WebKit/LayoutTests/http/tests/fetch/script-tests/fetch.js View 1 2 3 4 5 1 chunk +27 lines, -24 lines 0 comments Download
M third_party/WebKit/LayoutTests/http/tests/fetch/script-tests/thorough/scheme-blob.js View 1 2 3 4 5 1 chunk +25 lines, -20 lines 0 comments Download
M third_party/WebKit/LayoutTests/http/tests/serviceworker/webexposed/global-interface-listing-service-worker-expected.txt View 1 2 3 4 1 chunk +0 lines, -2 lines 0 comments Download
M third_party/WebKit/LayoutTests/virtual/stable/http/tests/serviceworker/webexposed/global-interface-listing-service-worker-expected.txt View 1 2 3 4 1 chunk +0 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/core/fileapi/URLFileAPI.cpp View 1 2 3 3 chunks +0 lines, -8 lines 0 comments Download
M third_party/WebKit/Source/core/fileapi/URLFileAPI.idl View 1 2 3 1 chunk +3 lines, -3 lines 0 comments Download
M third_party/WebKit/Source/core/frame/Deprecation.cpp View 1 2 3 1 chunk +0 lines, -6 lines 0 comments Download
M third_party/WebKit/Source/modules/mediasource/URLMediaSource.cpp View 1 2 3 2 chunks +0 lines, -6 lines 0 comments Download
M third_party/WebKit/Source/modules/mediasource/URLMediaSource.idl View 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/modules/mediastream/URLMediaStream.cpp View 1 2 3 2 chunks +0 lines, -5 lines 0 comments Download
M third_party/WebKit/Source/modules/mediastream/URLMediaStream.idl View 1 chunk +1 line, -1 line 0 comments Download

Messages

Total messages: 38 (15 generated)
jsbell
haraken@, can you do an initial review for the bindings change and/or suggest an alternate ...
4 years, 8 months ago (2016-04-21 23:55:18 UTC) #2
haraken
LGTM https://codereview.chromium.org/1908263002/diff/1/third_party/WebKit/Source/modules/mediasource/URLMediaSource.idl File third_party/WebKit/Source/modules/mediasource/URLMediaSource.idl (right): https://codereview.chromium.org/1908263002/diff/1/third_party/WebKit/Source/modules/mediasource/URLMediaSource.idl#newcode34 third_party/WebKit/Source/modules/mediasource/URLMediaSource.idl:34: [Exposed=(Window,DedicatedWorker,SharedWorker), CallWith=ExecutionContext] static DOMString? createObjectURL(MediaSource source); You're changing ...
4 years, 8 months ago (2016-04-22 00:11:00 UTC) #3
jsbell
https://codereview.chromium.org/1908263002/diff/1/third_party/WebKit/Source/modules/mediasource/URLMediaSource.idl File third_party/WebKit/Source/modules/mediasource/URLMediaSource.idl (right): https://codereview.chromium.org/1908263002/diff/1/third_party/WebKit/Source/modules/mediasource/URLMediaSource.idl#newcode34 third_party/WebKit/Source/modules/mediasource/URLMediaSource.idl:34: [Exposed=(Window,DedicatedWorker,SharedWorker), CallWith=ExecutionContext] static DOMString? createObjectURL(MediaSource source); On 2016/04/22 00:10:59, ...
4 years, 8 months ago (2016-04-22 00:16:26 UTC) #4
haraken
On 2016/04/22 00:16:26, jsbell wrote: > https://codereview.chromium.org/1908263002/diff/1/third_party/WebKit/Source/modules/mediasource/URLMediaSource.idl > File third_party/WebKit/Source/modules/mediasource/URLMediaSource.idl (right): > > https://codereview.chromium.org/1908263002/diff/1/third_party/WebKit/Source/modules/mediasource/URLMediaSource.idl#newcode34 > ...
4 years, 8 months ago (2016-04-22 00:30:59 UTC) #5
sof
https://codereview.chromium.org/1908263002/diff/1/third_party/WebKit/Source/core/fileapi/URLFileAPI.cpp File third_party/WebKit/Source/core/fileapi/URLFileAPI.cpp (right): https://codereview.chromium.org/1908263002/diff/1/third_party/WebKit/Source/core/fileapi/URLFileAPI.cpp#newcode19 third_party/WebKit/Source/core/fileapi/URLFileAPI.cpp:19: if (!executionContext) assert instead? i.e., can the current execution ...
4 years, 8 months ago (2016-04-22 06:19:29 UTC) #7
jsbell
On 2016/04/22 00:16:26, jsbell wrote: > The partials for MediaSource and MediaStream no longer exist ...
4 years, 8 months ago (2016-04-22 18:10:47 UTC) #8
jsbell
https://codereview.chromium.org/1908263002/diff/1/third_party/WebKit/Source/core/fileapi/URLFileAPI.cpp File third_party/WebKit/Source/core/fileapi/URLFileAPI.cpp (right): https://codereview.chromium.org/1908263002/diff/1/third_party/WebKit/Source/core/fileapi/URLFileAPI.cpp#newcode19 third_party/WebKit/Source/core/fileapi/URLFileAPI.cpp:19: if (!executionContext) On 2016/04/22 06:19:29, sof wrote: > assert ...
4 years, 8 months ago (2016-04-22 18:14:34 UTC) #9
jsbell
wolenetz@ - can you review the modules/mediasource change? tommi@ - can you review the modules/mediastream ...
4 years, 8 months ago (2016-04-22 18:19:11 UTC) #11
tommi (sloooow) - chröme
lgtm
4 years, 8 months ago (2016-04-25 10:20:26 UTC) #13
jsbell
FYI, I'm splitting the URLFileAPI-refactor part of this CL out on its own: https://codereview.chromium.org/1921063002 I'll ...
4 years, 8 months ago (2016-04-25 20:43:49 UTC) #14
wolenetz
lgtm (mediasource) jsbell@ : is there a crbug tracking the createFor() in URLFileAPI.idl? MediaSource might ...
4 years, 7 months ago (2016-05-02 19:22:03 UTC) #16
jsbell
On 2016/05/02 19:22:03, wolenetz wrote: > lgtm (mediasource) > jsbell@ : is there a crbug ...
4 years, 7 months ago (2016-05-02 20:24:41 UTC) #17
wolenetz
On 2016/05/02 20:24:41, jsbell wrote: > On 2016/05/02 19:22:03, wolenetz wrote: > > lgtm (mediasource) ...
4 years, 7 months ago (2016-05-02 20:27:26 UTC) #19
jsbell
yhirano@ - can you review the fetch test changes? This makes thorough/scheme-blob*.html a no-op in ...
4 years, 7 months ago (2016-05-10 19:00:55 UTC) #23
yhirano
lgtm Fetch tests are written in the service worker layout tests style[1]. Please keep the ...
4 years, 7 months ago (2016-05-11 01:54:05 UTC) #24
jsbell
rbyers@ - can you API_OWNERS review? yhirano@ - thanks for the detailed formatting feedback! Did ...
4 years, 7 months ago (2016-05-11 21:52:42 UTC) #26
Rick Byers
On 2016/05/11 21:52:42, jsbell wrote: > rbyers@ - can you API_OWNERS review? third_party/WebKit/LayoutTests/virtual/stable LGTM
4 years, 7 months ago (2016-05-12 01:07:08 UTC) #27
yhirano
On 2016/05/11 21:52:42, jsbell wrote: > rbyers@ - can you API_OWNERS review? > > yhirano@ ...
4 years, 7 months ago (2016-05-12 04:48:24 UTC) #28
yhirano
> Did we ever figure out clang-format settings for that style? (since I suspect I'll ...
4 years, 7 months ago (2016-05-12 04:49:15 UTC) #30
falken
On 2016/05/12 04:49:15, yhirano wrote: > > Did we ever figure out clang-format settings for ...
4 years, 7 months ago (2016-05-12 05:02:14 UTC) #31
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1908263002/100001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1908263002/100001
4 years, 7 months ago (2016-05-12 16:35:23 UTC) #34
commit-bot: I haz the power
Committed patchset #6 (id:100001)
4 years, 7 months ago (2016-05-12 16:39:08 UTC) #36
commit-bot: I haz the power
4 years, 7 months ago (2016-05-12 16:40:39 UTC) #38
Message was sent while issue was closed.
Patchset 6 (id:??) landed as
https://crrev.com/9e232c512c962a7aecc85e07f7a48a4735dc7a25
Cr-Commit-Position: refs/heads/master@{#393271}

Powered by Google App Engine
This is Rietveld 408576698