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

Issue 54233002: Make net::DataURL's MIME string check stricter (Closed)

Created:
7 years, 1 month ago by tyoshino (SeeGerritForStatus)
Modified:
6 years, 7 months ago
CC:
chromium-reviews, darin-cc_chromium.org
Visibility:
Public.

Description

Make net::DataURL's MIME string check stricter Existing IsMimeType is replaced with two methods: - ParseMimeTypeWithoutParameter: Checks grammar and parses given MIME type string - IsValidTopLevelMimeType: Checks if the given top level MIME type is valid one or not BUG=308768 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=272022

Patch Set 1 #

Total comments: 3

Patch Set 2 : Addressed abarth's comment on Blink side #

Total comments: 1

Patch Set 3 : sof and abarth's comment #

Total comments: 2

Patch Set 4 : Rebase and sof's comment #

Patch Set 5 : Rebase #

Total comments: 2

Patch Set 6 : Rebase #

Patch Set 7 : Rebase #

Total comments: 4

Patch Set 8 : Added grammar check code and unittests #

Patch Set 9 : #

Patch Set 10 : #

Patch Set 11 : #

Total comments: 3

Patch Set 12 : Use MimeUtil #

Patch Set 13 : Comment update #

Patch Set 14 : CONTENT_EXPORT #

Total comments: 6

Patch Set 15 : Addressed #36 #

Patch Set 16 : Revert credentials change #

Patch Set 17 : Fixed unittest #

Patch Set 18 : Rebase #

Patch Set 19 : Rebase #

Patch Set 20 : Split web_url_loader_impl change #

Unified diffs Side-by-side diffs Delta from patch set Stats (+150 lines, -73 lines) Patch
M content/browser/renderer_host/pepper/pepper_file_system_browser_host.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 1 chunk +6 lines, -4 lines 0 comments Download
M net/base/data_url.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 2 chunks +6 lines, -2 lines 0 comments Download
M net/base/data_url_unittest.cc View 1 2 3 4 5 6 7 1 chunk +7 lines, -0 lines 0 comments Download
M net/base/mime_util.h View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 1 chunk +22 lines, -4 lines 0 comments Download
M net/base/mime_util.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 4 chunks +44 lines, -34 lines 0 comments Download
M net/base/mime_util_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 1 chunk +65 lines, -29 lines 0 comments Download

Messages

Total messages: 45 (0 generated)
sof
https://codereview.chromium.org/54233002/diff/1/webkit/child/weburlloader_impl.cc File webkit/child/weburlloader_impl.cc (right): https://codereview.chromium.org/54233002/diff/1/webkit/child/weburlloader_impl.cc#newcode136 webkit/child/weburlloader_impl.cc:136: std::string raw_header = "HTTP/1.1 200 OK"; Possible to bring ...
7 years, 1 month ago (2013-10-31 08:19:31 UTC) #1
tyoshino (SeeGerritForStatus)
https://codereview.chromium.org/54233002/diff/1/webkit/child/weburlloader_impl.cc File webkit/child/weburlloader_impl.cc (right): https://codereview.chromium.org/54233002/diff/1/webkit/child/weburlloader_impl.cc#newcode136 webkit/child/weburlloader_impl.cc:136: std::string raw_header = "HTTP/1.1 200 OK"; On 2013/10/31 08:19:32, ...
7 years, 1 month ago (2013-10-31 08:53:20 UTC) #2
sof
https://codereview.chromium.org/54233002/diff/1/webkit/child/weburlloader_impl.cc File webkit/child/weburlloader_impl.cc (right): https://codereview.chromium.org/54233002/diff/1/webkit/child/weburlloader_impl.cc#newcode136 webkit/child/weburlloader_impl.cc:136: std::string raw_header = "HTTP/1.1 200 OK"; On 2013/10/31 08:53:20, ...
7 years, 1 month ago (2013-10-31 15:26:59 UTC) #3
abarth-chromium
https://codereview.chromium.org/54233002/diff/70001/webkit/child/weburlloader_impl.cc File webkit/child/weburlloader_impl.cc (right): https://codereview.chromium.org/54233002/diff/70001/webkit/child/weburlloader_impl.cc#newcode147 webkit/child/weburlloader_impl.cc:147: info->headers = new net::HttpResponseHeaders(raw_header); It seems like there should ...
7 years, 1 month ago (2013-11-01 16:48:55 UTC) #4
tyoshino (SeeGerritForStatus)
Changed to use AddHeader() and ReplaceStatusLine(). > I think there's also an implementation in the ...
7 years, 1 month ago (2013-11-01 17:02:28 UTC) #5
sof
The change looks fine to me; just a minor code comment. https://codereview.chromium.org/54233002/diff/110001/webkit/child/weburlloader_impl.cc File webkit/child/weburlloader_impl.cc (right): ...
7 years, 1 month ago (2013-11-08 13:34:33 UTC) #6
tyoshino (SeeGerritForStatus)
https://codereview.chromium.org/54233002/diff/110001/webkit/child/weburlloader_impl.cc File webkit/child/weburlloader_impl.cc (right): https://codereview.chromium.org/54233002/diff/110001/webkit/child/weburlloader_impl.cc#newcode139 webkit/child/weburlloader_impl.cc:139: std::string content_type_header = "Content-Type: " + mime_type; On 2013/11/08 ...
7 years, 1 month ago (2013-11-12 05:47:26 UTC) #7
sof
On 2013/11/12 05:47:26, tyoshino wrote: .. > > Thanks. I see. It's well documented in ...
7 years, 1 month ago (2013-11-12 07:05:23 UTC) #8
sof
https://codereview.chromium.org/54233002/diff/180001/webkit/child/weburlloader_impl.cc File webkit/child/weburlloader_impl.cc (right): https://codereview.chromium.org/54233002/diff/180001/webkit/child/weburlloader_impl.cc#newcode144 webkit/child/weburlloader_impl.cc:144: headers->AddHeader("Access-Control-Allow-Origin: *"); Thinking about this a bit more, this ...
7 years, 1 month ago (2013-11-22 21:42:35 UTC) #9
tyoshino (SeeGerritForStatus)
https://codereview.chromium.org/54233002/diff/180001/webkit/child/weburlloader_impl.cc File webkit/child/weburlloader_impl.cc (right): https://codereview.chromium.org/54233002/diff/180001/webkit/child/weburlloader_impl.cc#newcode144 webkit/child/weburlloader_impl.cc:144: headers->AddHeader("Access-Control-Allow-Origin: *"); On 2013/11/22 21:42:35, sof wrote: > Thinking ...
6 years, 9 months ago (2014-03-11 06:40:37 UTC) #10
sof
On 2014/03/11 06:40:37, tyoshino wrote: > https://codereview.chromium.org/54233002/diff/180001/webkit/child/weburlloader_impl.cc > File webkit/child/weburlloader_impl.cc (right): > > https://codereview.chromium.org/54233002/diff/180001/webkit/child/weburlloader_impl.cc#newcode144 > ...
6 years, 9 months ago (2014-03-11 06:44:50 UTC) #11
tyoshino (SeeGerritForStatus)
On 2013/11/01 17:02:28, tyoshino wrote: > > I think there's also an implementation in the ...
6 years, 9 months ago (2014-03-11 06:47:22 UTC) #12
tyoshino (SeeGerritForStatus)
On 2014/03/11 06:44:50, sof wrote: > On 2014/03/11 06:40:37, tyoshino wrote: > > > https://codereview.chromium.org/54233002/diff/180001/webkit/child/weburlloader_impl.cc ...
6 years, 9 months ago (2014-03-11 06:56:28 UTC) #13
sof
On 2014/03/11 06:56:28, tyoshino wrote: > On 2014/03/11 06:44:50, sof wrote: > > On 2014/03/11 ...
6 years, 9 months ago (2014-03-11 07:09:19 UTC) #14
tyoshino (SeeGerritForStatus)
I rebased this and did manual test again. It turned out that this CL requires ...
6 years, 9 months ago (2014-03-11 07:27:01 UTC) #15
abarth-chromium
Test? I'm not sure whether you've addressed sof's questions...
6 years, 9 months ago (2014-03-11 07:34:34 UTC) #16
sof
On 2014/03/11 07:34:34, abarth wrote: > Test? > > I'm not sure whether you've addressed ...
6 years, 9 months ago (2014-03-11 07:51:12 UTC) #17
tyoshino (SeeGerritForStatus)
On 2014/03/11 07:51:12, sof wrote: > On 2014/03/11 07:34:34, abarth wrote: > > Test? I'll ...
6 years, 9 months ago (2014-03-11 08:20:57 UTC) #18
tyoshino (SeeGerritForStatus)
On 2014/03/11 08:20:57, tyoshino wrote: > On 2014/03/11 07:51:12, sof wrote: > > On 2014/03/11 ...
6 years, 9 months ago (2014-03-12 07:31:34 UTC) #19
sof
On 2014/03/12 07:31:34, tyoshino wrote: > On 2014/03/11 08:20:57, tyoshino wrote: > > On 2014/03/11 ...
6 years, 9 months ago (2014-03-12 07:54:14 UTC) #20
robwu
tyoshino: withCredentials for wildcard origins is supported for non-http(s) URLs since https://codereview.chromium.org/192573011/. Could you add ...
6 years, 9 months ago (2014-03-17 20:26:53 UTC) #21
tyoshino (SeeGerritForStatus)
On 2014/03/17 20:26:53, robwu wrote: > tyoshino: > withCredentials for wildcard origins is supported for ...
6 years, 9 months ago (2014-03-18 13:22:45 UTC) #22
tyoshino (SeeGerritForStatus)
abarth: ping
6 years, 9 months ago (2014-03-24 12:35:16 UTC) #23
abarth-chromium
This CL is missing a test. https://codereview.chromium.org/54233002/diff/260001/content/child/web_url_loader_impl.cc File content/child/web_url_loader_impl.cc (right): https://codereview.chromium.org/54233002/diff/260001/content/child/web_url_loader_impl.cc#newcode147 content/child/web_url_loader_impl.cc:147: "Content-Type: " + ...
6 years, 9 months ago (2014-03-24 16:40:30 UTC) #24
tyoshino (SeeGerritForStatus)
https://codereview.chromium.org/54233002/diff/260001/content/child/web_url_loader_impl.cc File content/child/web_url_loader_impl.cc (right): https://codereview.chromium.org/54233002/diff/260001/content/child/web_url_loader_impl.cc#newcode150 content/child/web_url_loader_impl.cc:150: headers->AddHeader("Access-Control-Allow-Credentials: true"); On 2014/03/24 16:40:30, abarth wrote: > I ...
6 years, 9 months ago (2014-03-24 19:36:57 UTC) #25
tyoshino (SeeGerritForStatus)
https://codereview.chromium.org/54233002/diff/260001/content/child/web_url_loader_impl.cc File content/child/web_url_loader_impl.cc (right): https://codereview.chromium.org/54233002/diff/260001/content/child/web_url_loader_impl.cc#newcode147 content/child/web_url_loader_impl.cc:147: "Content-Type: " + mime_type + ";charset=" + charset; On ...
6 years, 9 months ago (2014-03-26 17:34:07 UTC) #26
tyoshino (SeeGerritForStatus)
+asanka for net/ review
6 years, 9 months ago (2014-03-26 17:37:59 UTC) #27
asanka
https://codereview.chromium.org/54233002/diff/340001/net/base/data_url.cc File net/base/data_url.cc (right): https://codereview.chromium.org/54233002/diff/340001/net/base/data_url.cc#newcode67 net/base/data_url.cc:67: // Check grammar. Consider using IsMimeType() instead?
6 years, 9 months ago (2014-03-26 19:42:08 UTC) #28
tyoshino (SeeGerritForStatus)
https://codereview.chromium.org/54233002/diff/340001/net/base/data_url.cc File net/base/data_url.cc (right): https://codereview.chromium.org/54233002/diff/340001/net/base/data_url.cc#newcode67 net/base/data_url.cc:67: // Check grammar. On 2014/03/26 19:42:09, asanka wrote: > ...
6 years, 9 months ago (2014-03-26 22:07:00 UTC) #29
asanka
https://codereview.chromium.org/54233002/diff/340001/net/base/data_url.cc File net/base/data_url.cc (right): https://codereview.chromium.org/54233002/diff/340001/net/base/data_url.cc#newcode67 net/base/data_url.cc:67: // Check grammar. On 2014/03/26 22:07:00, tyoshino wrote: > ...
6 years, 9 months ago (2014-03-26 22:29:42 UTC) #30
tyoshino (SeeGerritForStatus)
On 2014/03/26 22:29:42, asanka wrote: > > As web_intents_registry.cc has gone and the only user ...
6 years, 9 months ago (2014-03-27 05:48:28 UTC) #31
tyoshino (SeeGerritForStatus)
Added tzik@ to ensure I'm doing right for pepper_.* file.
6 years, 9 months ago (2014-03-27 05:50:05 UTC) #32
tzik
On 2014/03/27 05:50:05, tyoshino wrote: > Added tzik@ to ensure I'm doing right for pepper_.* ...
6 years, 9 months ago (2014-03-27 06:22:57 UTC) #33
nhiroki
On 2014/03/27 06:22:57, tzik wrote: > On 2014/03/27 05:50:05, tyoshino wrote: > > Added tzik@ ...
6 years, 9 months ago (2014-03-27 06:53:20 UTC) #34
dmichael (off chromium)
pepper lgtm
6 years, 9 months ago (2014-03-27 15:53:04 UTC) #35
asanka
net/ lgtm https://codereview.chromium.org/54233002/diff/390001/net/base/data_url.cc File net/base/data_url.cc (right): https://codereview.chromium.org/54233002/diff/390001/net/base/data_url.cc#newcode66 net/base/data_url.cc:66: } else { Nit: else if https://codereview.chromium.org/54233002/diff/390001/net/base/mime_util.h ...
6 years, 9 months ago (2014-03-27 18:59:51 UTC) #36
tyoshino (SeeGerritForStatus)
Thanks for review, pepper and net guys. https://codereview.chromium.org/54233002/diff/390001/net/base/data_url.cc File net/base/data_url.cc (right): https://codereview.chromium.org/54233002/diff/390001/net/base/data_url.cc#newcode66 net/base/data_url.cc:66: } else ...
6 years, 8 months ago (2014-03-31 13:02:45 UTC) #37
tyoshino (SeeGerritForStatus)
Had offline discussion with abarth@. Updated the CL description to explain decisions we made. abarth@, ...
6 years, 8 months ago (2014-04-08 16:12:34 UTC) #38
tyoshino (SeeGerritForStatus)
On 2014/04/08 16:12:34, tyoshino wrote: > Had offline discussion with abarth@. Updated the CL description ...
6 years, 7 months ago (2014-05-21 09:36:19 UTC) #39
tyoshino (SeeGerritForStatus)
The CQ bit was checked by tyoshino@chromium.org
6 years, 7 months ago (2014-05-21 11:21:27 UTC) #40
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/tyoshino@chromium.org/54233002/510001
6 years, 7 months ago (2014-05-21 11:22:53 UTC) #41
tyoshino (SeeGerritForStatus)
The CQ bit was unchecked by tyoshino@chromium.org
6 years, 7 months ago (2014-05-21 17:04:44 UTC) #42
tyoshino (SeeGerritForStatus)
The CQ bit was checked by tyoshino@chromium.org
6 years, 7 months ago (2014-05-21 17:05:00 UTC) #43
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/tyoshino@chromium.org/54233002/510001
6 years, 7 months ago (2014-05-21 19:58:09 UTC) #44
commit-bot: I haz the power
6 years, 7 months ago (2014-05-21 23:52:11 UTC) #45
Message was sent while issue was closed.
Change committed as 272022

Powered by Google App Engine
This is Rietveld 408576698