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

Issue 2685543002: Support data URLs in worker constructors (Closed)

Created:
3 years, 10 months ago by andypaicu2
Modified:
3 years, 10 months ago
CC:
blink-reviews, blink-worker-reviews_chromium.org, chromium-reviews, falken+watch_chromium.org, horo+watch_chromium.org, kinuko+worker_chromium.org, shimazu+worker_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Support data URLs in worker constructors to be inline with spec. Changes made: - Allow Cross Origin Requests when trying to retrieve the URL resources if it's a data URL (for workers only) - Enhanced data-url and data-url-shared external wpt tests and removed the failure test expectations for these tests BUG=270979, 655458, 508730 Review-Url: https://codereview.chromium.org/2685543002 Cr-Commit-Position: refs/heads/master@{#450358} Committed: https://chromium.googlesource.com/chromium/src/+/9801daec162285a1f2c6695682ace5d508ea9b7f

Patch Set 1 #

Patch Set 2 : Changes to allow data URL workers #

Total comments: 6

Patch Set 3 : Implemented Pass 2 code review suggestions. Removed external/wpt/workers/data-url.html from the lis… #

Total comments: 12

Patch Set 4 : Made SharedWorkers work with 'data:' URLs. Implemented suggested code review change #

Patch Set 5 : Added external tests for data: SharedWorkers #

Total comments: 2

Patch Set 6 : Added additional test for invalid javascript data: worker #

Total comments: 3
Unified diffs Side-by-side diffs Delta from patch set Stats (+95 lines, -19 lines) Patch
M third_party/WebKit/LayoutTests/TestExpectations View 1 2 3 4 5 2 chunks +0 lines, -2 lines 0 comments Download
M third_party/WebKit/LayoutTests/external/wpt/workers/data-url.html View 1 2 3 4 5 1 chunk +51 lines, -8 lines 3 comments Download
M third_party/WebKit/LayoutTests/external/wpt/workers/data-url-shared.html View 1 2 3 4 5 1 chunk +29 lines, -6 lines 0 comments Download
M third_party/WebKit/Source/core/loader/DocumentThreadableLoader.cpp View 1 2 3 1 chunk +2 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/workers/AbstractWorker.cpp View 1 chunk +2 lines, -1 line 0 comments Download
M third_party/WebKit/Source/core/workers/InProcessWorkerBase.cpp View 1 2 1 chunk +5 lines, -1 line 0 comments Download
M third_party/WebKit/Source/web/WebSharedWorkerImpl.cpp View 1 2 3 4 5 1 chunk +6 lines, -1 line 0 comments Download

Messages

Total messages: 50 (35 generated)
Mike West
Thanks! Here's a first pass! Please also update the CL description with some details about ...
3 years, 10 months ago (2017-02-08 13:15:44 UTC) #8
Mike West
https://codereview.chromium.org/2685543002/diff/40001/third_party/WebKit/LayoutTests/TestExpectations File third_party/WebKit/LayoutTests/TestExpectations (left): https://codereview.chromium.org/2685543002/diff/40001/third_party/WebKit/LayoutTests/TestExpectations#oldcode2077 third_party/WebKit/LayoutTests/TestExpectations:2077: crbug.com/508730 external/wpt/workers/data-url.html [ Failure ] Will you be dealing ...
3 years, 10 months ago (2017-02-08 15:18:53 UTC) #11
jochen (gone - plz use gerrit)
can you also add a test where we pass a data: URL with an invalid ...
3 years, 10 months ago (2017-02-10 09:57:37 UTC) #15
andypaicu2
On 2017/02/08 at 13:15:44, mkwst wrote: > Thanks! Here's a first pass! > > Please ...
3 years, 10 months ago (2017-02-10 10:25:10 UTC) #23
andypaicu2
https://codereview.chromium.org/2685543002/diff/20001/third_party/WebKit/LayoutTests/http/tests/workers/worker-allow-data-url.html File third_party/WebKit/LayoutTests/http/tests/workers/worker-allow-data-url.html (right): https://codereview.chromium.org/2685543002/diff/20001/third_party/WebKit/LayoutTests/http/tests/workers/worker-allow-data-url.html#newcode1 third_party/WebKit/LayoutTests/http/tests/workers/worker-allow-data-url.html:1: <!doctype html> On 2017/02/08 at 13:15:44, Mike West (sloooooow) ...
3 years, 10 months ago (2017-02-10 10:25:38 UTC) #24
andypaicu2
On 2017/02/10 at 09:57:37, jochen wrote: > can you also add a test where we ...
3 years, 10 months ago (2017-02-13 11:35:51 UTC) #25
andypaicu2
Added patch with changes. https://codereview.chromium.org/2685543002/diff/80001/third_party/WebKit/Source/web/WebSharedWorkerImpl.cpp File third_party/WebKit/Source/web/WebSharedWorkerImpl.cpp (right): https://codereview.chromium.org/2685543002/diff/80001/third_party/WebKit/Source/web/WebSharedWorkerImpl.cpp#newcode183 third_party/WebKit/Source/web/WebSharedWorkerImpl.cpp:183: ((KURL)m_url).protocolIsData() ? AllowCrossOriginRequests On 2017/02/10 ...
3 years, 10 months ago (2017-02-13 11:38:45 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/2685543002/100001
3 years, 10 months ago (2017-02-13 11:38:55 UTC) #29
commit-bot: I haz the power
No L-G-T-M from a valid reviewer yet. CQ run can only be started by full ...
3 years, 10 months ago (2017-02-13 11:38:57 UTC) #31
jochen (gone - plz use gerrit)
lgtm once the tests pass
3 years, 10 months ago (2017-02-14 08:57:24 UTC) #37
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/2685543002/100001
3 years, 10 months ago (2017-02-14 15:23:15 UTC) #43
commit-bot: I haz the power
Committed patchset #6 (id:100001) as https://chromium.googlesource.com/chromium/src/+/9801daec162285a1f2c6695682ace5d508ea9b7f
3 years, 10 months ago (2017-02-14 15:28:28 UTC) #46
Marijn Kruisselbrink
https://codereview.chromium.org/2685543002/diff/100001/third_party/WebKit/LayoutTests/external/wpt/workers/data-url.html File third_party/WebKit/LayoutTests/external/wpt/workers/data-url.html (right): https://codereview.chromium.org/2685543002/diff/100001/third_party/WebKit/LayoutTests/external/wpt/workers/data-url.html#newcode45 third_party/WebKit/LayoutTests/external/wpt/workers/data-url.html:45: assert_worker_throws('indexedDB inaccessible', 'self.indexedDB.open("someDBName")'); I'm not convinced that this is ...
3 years, 10 months ago (2017-02-14 18:38:10 UTC) #48
jochen (gone - plz use gerrit)
https://codereview.chromium.org/2685543002/diff/100001/third_party/WebKit/LayoutTests/external/wpt/workers/data-url.html File third_party/WebKit/LayoutTests/external/wpt/workers/data-url.html (right): https://codereview.chromium.org/2685543002/diff/100001/third_party/WebKit/LayoutTests/external/wpt/workers/data-url.html#newcode45 third_party/WebKit/LayoutTests/external/wpt/workers/data-url.html:45: assert_worker_throws('indexedDB inaccessible', 'self.indexedDB.open("someDBName")'); On 2017/02/14 at 18:38:10, Marijn Kruisselbrink ...
3 years, 10 months ago (2017-02-14 19:19:27 UTC) #49
andypaicu2
3 years, 10 months ago (2017-02-15 08:42:10 UTC) #50
Message was sent while issue was closed.
On 2017/02/14 at 18:38:10, mek wrote:
>
https://codereview.chromium.org/2685543002/diff/100001/third_party/WebKit/Lay...
> File third_party/WebKit/LayoutTests/external/wpt/workers/data-url.html
(right):
> 
>
https://codereview.chromium.org/2685543002/diff/100001/third_party/WebKit/Lay...
> third_party/WebKit/LayoutTests/external/wpt/workers/data-url.html:45:
assert_worker_throws('indexedDB inaccessible',
'self.indexedDB.open("someDBName")');
> I'm not convinced that this is actually spec compliant (I don't see anywhere
in the IDB spec where it is supposed to throw for trying to open a db from an
opaque origin).
> 
>
https://codereview.chromium.org/2685543002/diff/100001/third_party/WebKit/Lay...
> third_party/WebKit/LayoutTests/external/wpt/workers/data-url.html:46:
assert_worker_throws('localStorage inaccessible', 'self.localStorage.testItem');
> This test makes no sense. Workers don't have localStorage under any
circumstance, so I'm not sure what this is trying to test?

Removed localStorage test. And added a new websql test. New codereview created
for this: https://codereview.chromium.org/2697003002.

Powered by Google App Engine
This is Rietveld 408576698