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

Issue 1356353003: Relax cross-origin partial response requirements for CORS presence. (Closed)

Created:
5 years, 3 months ago by DaleCurtis
Modified:
5 years, 2 months ago
CC:
chromium-reviews, feature-media-reviews_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Relax cross-origin partial response requirements for CORS presence. Per discussion on the bug, if the redirect passes a CORS we should allow the mixing of origins. DidPassCORSAccessCheck() will ensure each request passes the crossorigin test. Prior to this fix, crossOrigin redirects for video were always broken, this fix also allows 'range' to be a simple header when a client has requested no preflight. BUG=532569 TEST=new unittest, manually verified exploit fails if crossorigin set. Committed: https://crrev.com/e11ea5ed677321f5fa24e8e77b01f8f57a0098a5 Cr-Commit-Position: refs/heads/master@{#355452}

Patch Set 1 #

Total comments: 2

Patch Set 2 : Add exception for range, merge tests. #

Patch Set 3 : Revert accidental php change. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+142 lines, -13 lines) Patch
M media/blink/buffered_data_source.cc View 1 chunk +4 lines, -3 lines 0 comments Download
M media/blink/buffered_data_source_unittest.cc View 4 chunks +26 lines, -7 lines 0 comments Download
M third_party/WebKit/LayoutTests/http/tests/media/mixed-range-response.html View 1 4 chunks +95 lines, -2 lines 0 comments Download
M third_party/WebKit/LayoutTests/http/tests/media/resources/load-video.php View 1 2 1 chunk +2 lines, -0 lines 0 comments Download
M third_party/WebKit/LayoutTests/http/tests/media/resources/mixed-range-response.php View 1 2 chunks +6 lines, -0 lines 0 comments Download
M third_party/WebKit/LayoutTests/http/tests/media/resources/serve-video.php View 1 1 chunk +3 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/loader/DocumentThreadableLoader.cpp View 1 2 1 chunk +6 lines, -1 line 0 comments Download

Messages

Total messages: 50 (10 generated)
DaleCurtis
+horo, evn to vet this.
5 years, 3 months ago (2015-09-22 21:57:50 UTC) #2
evn
https://codereview.chromium.org/1356353003/diff/1/media/blink/buffered_data_source.cc File media/blink/buffered_data_source.cc (right): https://codereview.chromium.org/1356353003/diff/1/media/blink/buffered_data_source.cc#newcode437 media/blink/buffered_data_source.cc:437: DidPassCORSAccessCheck(); where can I see the code for DidPassCORSAccessCheck()? ...
5 years, 3 months ago (2015-09-23 10:11:54 UTC) #3
DaleCurtis
https://codereview.chromium.org/1356353003/diff/1/media/blink/buffered_data_source.cc File media/blink/buffered_data_source.cc (right): https://codereview.chromium.org/1356353003/diff/1/media/blink/buffered_data_source.cc#newcode437 media/blink/buffered_data_source.cc:437: DidPassCORSAccessCheck(); On 2015/09/23 10:11:54, evn wrote: > where can ...
5 years, 3 months ago (2015-09-23 15:56:12 UTC) #4
evn
DidPassCORSAccessCheck() seems to just check if the element has a crossorigin attribute, right?
5 years, 3 months ago (2015-09-23 19:29:54 UTC) #5
DaleCurtis
Yes, it's expecting WebURLLoader to enforce the CORS option and fail to load if CORS ...
5 years, 3 months ago (2015-09-23 22:20:12 UTC) #6
horo
Looks good. But please add LayoutTest case in http/tests/media/mixed-range-response.html for this change.
5 years, 3 months ago (2015-09-24 06:59:52 UTC) #7
chromium-reviews
Thanks Dale, rather than keep on asking you questions I'll just say what I had ...
5 years, 3 months ago (2015-09-24 07:59:59 UTC) #8
horo
> 2. If a Service Worker intercepts the request and makes it non-cors who > ...
5 years, 2 months ago (2015-09-25 03:17:06 UTC) #9
chromium-reviews
OK thanks horo :-) To unsubscribe from this group and stop receiving emails from it, ...
5 years, 2 months ago (2015-09-25 07:57:57 UTC) #10
DaleCurtis
On 2015/09/24 06:59:52, horo wrote: > Looks good. > But please add LayoutTest case in ...
5 years, 2 months ago (2015-09-27 18:48:19 UTC) #11
horo
On 2015/09/27 18:48:19, DaleCurtis wrote: > On 2015/09/24 06:59:52, horo wrote: > > Looks good. ...
5 years, 2 months ago (2015-09-28 06:04:59 UTC) #12
DaleCurtis
Thanks for the test tip! I admittedly hadn't tried, just looked at the server code ...
5 years, 2 months ago (2015-09-28 16:58:29 UTC) #14
DaleCurtis
+sigbjorn, specifying PreventPreflight for range requests seems incorrect given the comments on the code review ...
5 years, 2 months ago (2015-09-28 21:54:19 UTC) #16
hubbe
On 2015/09/28 21:54:19, DaleCurtis wrote: > +sigbjorn, specifying PreventPreflight for range requests seems incorrect given ...
5 years, 2 months ago (2015-09-28 23:05:24 UTC) #17
sigbjorn
On 2015/09/28 21:54:19, DaleCurtis wrote: > @sigbjorn, do you have some further > context to ...
5 years, 2 months ago (2015-09-29 07:06:51 UTC) #18
sof
On 2015/09/28 21:54:19, DaleCurtis wrote: > +sigbjorn, specifying PreventPreflight for range requests seems incorrect given ...
5 years, 2 months ago (2015-09-29 07:31:32 UTC) #19
evn
You can make the attack they are trying to protect against in Apache with Service ...
5 years, 2 months ago (2015-09-29 08:48:07 UTC) #20
DaleCurtis
Hmm, so it sounds like we don't want to add range to simple headers. What ...
5 years, 2 months ago (2015-09-29 18:58:58 UTC) #21
DaleCurtis
5 years, 2 months ago (2015-09-29 18:59:56 UTC) #23
DaleCurtis
I'm heading OOO on Oct2, so I've gone ahead and uploaded a patch set which ...
5 years, 2 months ago (2015-09-29 21:53:54 UTC) #24
hubbe
lgtm
5 years, 2 months ago (2015-10-05 17:28:08 UTC) #25
hubbe
Can I please get some l-g-t-m-s here? people are chomping at the bits to get ...
5 years, 2 months ago (2015-10-05 23:29:54 UTC) #26
horo
+tyoshion@ who is a specialist in CORS.
5 years, 2 months ago (2015-10-06 06:48:53 UTC) #28
tyoshino (SeeGerritForStatus)
On 2015/10/06 06:48:53, horo wrote: > +tyoshion@ who is a specialist in CORS. I agree ...
5 years, 2 months ago (2015-10-07 07:49:08 UTC) #29
tyoshino (SeeGerritForStatus)
On 2015/10/07 07:49:08, tyoshino wrote: > One concern I just come up with but different ...
5 years, 2 months ago (2015-10-07 07:56:24 UTC) #30
tyoshino (SeeGerritForStatus)
On 2015/10/07 07:56:24, tyoshino wrote: > On 2015/10/07 07:49:08, tyoshino wrote: > > One concern ...
5 years, 2 months ago (2015-10-07 07:57:16 UTC) #31
tyoshino (SeeGerritForStatus)
On 2015/10/07 07:57:16, tyoshino wrote: > On 2015/10/07 07:56:24, tyoshino wrote: > > On 2015/10/07 ...
5 years, 2 months ago (2015-10-07 08:12:42 UTC) #32
tyoshino (SeeGerritForStatus)
I wrote a very long reply but what I want you to change is just ...
5 years, 2 months ago (2015-10-08 05:56:41 UTC) #33
tyoshino (SeeGerritForStatus)
+mkwst I'd like Mike to check if my analysis #29- is correct.
5 years, 2 months ago (2015-10-08 14:38:42 UTC) #35
DaleCurtis
On 2015/10/08 05:56:41, tyoshino wrote: > I wrote a very long reply but what I ...
5 years, 2 months ago (2015-10-19 23:30:36 UTC) #36
DaleCurtis
I pinged Mike via e-mail. tyoshino@ can you respond to my last comment? Thanks!
5 years, 2 months ago (2015-10-21 00:25:23 UTC) #37
tyoshino (SeeGerritForStatus)
On 2015/10/21 00:25:23, DaleCurtis wrote: > I pinged Mike via e-mail. tyoshino@ can you respond ...
5 years, 2 months ago (2015-10-21 04:24:08 UTC) #38
Mike West
On 2015/10/21 at 04:24:08, tyoshino wrote: > On 2015/10/21 00:25:23, DaleCurtis wrote: > > I ...
5 years, 2 months ago (2015-10-21 07:05:40 UTC) #39
tyoshino (SeeGerritForStatus)
On 2015/10/21 07:05:40, Mike West (slow) wrote: > On 2015/10/21 at 04:24:08, tyoshino wrote: > ...
5 years, 2 months ago (2015-10-21 07:29:02 UTC) #40
DaleCurtis
Thanks for the reviews everyone, CQ'ing this CL based on the current approvals. Please yell ...
5 years, 2 months ago (2015-10-21 17:39:12 UTC) #41
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1356353003/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1356353003/20001
5 years, 2 months ago (2015-10-21 17:40:24 UTC) #43
commit-bot: I haz the power
Try jobs failed on following builders: linux_chromium_rel_ng on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/linux_chromium_rel_ng/builds/129596)
5 years, 2 months ago (2015-10-21 18:53:00 UTC) #45
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1356353003/40001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1356353003/40001
5 years, 2 months ago (2015-10-21 23:14:27 UTC) #48
commit-bot: I haz the power
Committed patchset #3 (id:40001)
5 years, 2 months ago (2015-10-22 00:26:34 UTC) #49
commit-bot: I haz the power
5 years, 2 months ago (2015-10-22 00:27:19 UTC) #50
Message was sent while issue was closed.
Patchset 3 (id:??) landed as
https://crrev.com/e11ea5ed677321f5fa24e8e77b01f8f57a0098a5
Cr-Commit-Position: refs/heads/master@{#355452}

Powered by Google App Engine
This is Rietveld 408576698