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

Issue 1072933006: Support whitelisting to handle insecure origins as trustworthy origins (chromium) (Closed)

Created:
5 years, 8 months ago by kinuko
Modified:
5 years, 7 months ago
CC:
chromium-reviews, darin-cc_chromium.org, jam, serviceworker-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Support whitelisting to handle insecure origins as trustworthy origins The whitelist is given and initialized via --unsafety-treat-insecure-origin-as-secure command-line flag. This needs to be specified with --user-data-dir to take effect. Specifying this flag shows a security banner: "You are using unsupported command-line flag: .... Stability and security will suffer." Depends on blink-side patch: https://codereview.chromium.org/1082173003/ BUG=441605 TEST=manual (to see SW on http works with command-line flag & the security banner is shown) TEST=unit_tests:SecureOriginWhiteList.UnsafetyTreatInsecureOriginAsSecure TEST=content_unittests:URLSchemesTest.IsOriginSecure TEST=content_unittests:ServiceWorkerDispatcherHostTest.* Committed: https://crrev.com/aaff1f6f8942f714a85a097228dd1e0fb13a36b8 Cr-Commit-Position: refs/heads/master@{#327875}

Patch Set 1 : #

Patch Set 2 : added test, added IsOriginSecure plumbing etc #

Total comments: 14

Patch Set 3 : moving IsOriginSecure from //chrome to //content #

Patch Set 4 : fixed SW tests #

Patch Set 5 : fix android build #

Patch Set 6 : rebase #

Patch Set 7 : Split the change into two #

Patch Set 8 : rebase #

Patch Set 9 : #

Patch Set 10 : #

Total comments: 2

Patch Set 11 : #

Total comments: 4

Patch Set 12 : added more tests #

Unified diffs Side-by-side diffs Delta from patch set Stats (+119 lines, -3 lines) Patch
M chrome/browser/chrome_content_browser_client.cc View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/ui/startup/bad_flags_prompt.cc View 1 2 1 chunk +4 lines, -0 lines 0 comments Download
M chrome/chrome_common.gypi View 1 2 3 4 5 6 7 8 9 10 1 chunk +2 lines, -0 lines 0 comments Download
M chrome/chrome_tests_unit.gypi View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +1 line, -0 lines 0 comments Download
M chrome/common/chrome_content_client.cc View 1 2 3 4 5 6 7 8 2 chunks +2 lines, -3 lines 0 comments Download
M chrome/common/chrome_switches.cc View 1 2 3 4 5 6 7 8 9 10 1 chunk +8 lines, -0 lines 0 comments Download
A chrome/common/secure_origin_whitelist.h View 1 2 3 4 5 6 7 8 1 chunk +18 lines, -0 lines 0 comments Download
A chrome/common/secure_origin_whitelist.cc View 1 2 3 4 5 6 7 8 1 chunk +27 lines, -0 lines 0 comments Download
A chrome/common/secure_origin_whitelist_unittest.cc View 1 2 3 4 5 6 7 8 9 10 11 1 chunk +41 lines, -0 lines 0 comments Download
M chrome/renderer/chrome_content_renderer_client.cc View 1 2 3 4 5 6 7 8 9 10 11 2 chunks +8 lines, -0 lines 0 comments Download
M content/common/origin_util.cc View 1 2 3 4 5 6 7 1 chunk +4 lines, -0 lines 0 comments Download
M content/public/common/origin_util.h View 1 2 3 4 5 6 7 8 9 1 chunk +3 lines, -0 lines 0 comments Download

Messages

Total messages: 38 (8 generated)
kinuko
jochen@, palmer@: could you take a look? (I'm slightly unsure how content and chrome wiring ...
5 years, 8 months ago (2015-04-20 08:17:10 UTC) #3
palmer
https://codereview.chromium.org/1072933006/diff/40001/chrome/browser/ui/startup/bad_flags_prompt.cc File chrome/browser/ui/startup/bad_flags_prompt.cc (right): https://codereview.chromium.org/1072933006/diff/40001/chrome/browser/ui/startup/bad_flags_prompt.cc#newcode83 chrome/browser/ui/startup/bad_flags_prompt.cc:83: // This flag adds whitelisting to disable the Secure ...
5 years, 8 months ago (2015-04-20 22:16:18 UTC) #4
jochen (gone - plz use gerrit)
it would be nice if this was a content-only features, so other embedders can use ...
5 years, 8 months ago (2015-04-21 09:45:48 UTC) #5
kinuko
Thanks. https://codereview.chromium.org/1072933006/diff/40001/chrome/common/origin_util.cc File chrome/common/origin_util.cc (right): https://codereview.chromium.org/1072933006/diff/40001/chrome/common/origin_util.cc#newcode30 chrome/common/origin_util.cc:30: if (content::IsOriginSecure(url)) On 2015/04/20 22:16:18, palmer wrote: > ...
5 years, 8 months ago (2015-04-21 12:26:07 UTC) #6
kinuko
Updated, PTAL https://codereview.chromium.org/1072933006/diff/40001/chrome/browser/ui/startup/bad_flags_prompt.cc File chrome/browser/ui/startup/bad_flags_prompt.cc (right): https://codereview.chromium.org/1072933006/diff/40001/chrome/browser/ui/startup/bad_flags_prompt.cc#newcode83 chrome/browser/ui/startup/bad_flags_prompt.cc:83: // This flag adds whitelisting to disable ...
5 years, 8 months ago (2015-04-21 16:15:48 UTC) #7
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1072933006/100001
5 years, 8 months ago (2015-04-22 12:43:07 UTC) #9
kinuko
Rebased on ToT. Could you PTAL? We want this to land. (If it helps I ...
5 years, 8 months ago (2015-04-23 01:19:39 UTC) #11
kinuko
On 2015/04/23 01:19:39, kinuko wrote: > Rebased on ToT. Could you PTAL? We want this ...
5 years, 8 months ago (2015-04-23 01:59:06 UTC) #12
palmer
LGTM, thanks!
5 years, 8 months ago (2015-04-23 19:21:16 UTC) #13
kinuko
jochen@ could you do owner review? Thanks,
5 years, 8 months ago (2015-04-24 04:46:59 UTC) #14
jochen (gone - plz use gerrit)
can we move the command line option to content as well, so we can also ...
5 years, 8 months ago (2015-04-24 14:04:44 UTC) #15
kinuko
On 2015/04/24 14:04:44, jochen wrote: > can we move the command line option to content ...
5 years, 8 months ago (2015-04-24 22:01:20 UTC) #16
jochen (gone - plz use gerrit)
On 2015/04/24 at 22:01:20, kinuko wrote: > On 2015/04/24 14:04:44, jochen wrote: > > can ...
5 years, 8 months ago (2015-04-27 19:30:16 UTC) #17
kinuko
On 2015/04/27 19:30:16, jochen wrote: > On 2015/04/24 at 22:01:20, kinuko wrote: > > On ...
5 years, 7 months ago (2015-04-28 03:11:56 UTC) #18
jochen (gone - plz use gerrit)
On 2015/04/28 at 03:11:56, kinuko wrote: > On 2015/04/27 19:30:16, jochen wrote: > > On ...
5 years, 7 months ago (2015-04-28 12:01:57 UTC) #20
kinuko
On 2015/04/28 12:01:57, jochen wrote: > On 2015/04/28 at 03:11:56, kinuko wrote: > > On ...
5 years, 7 months ago (2015-04-28 13:05:58 UTC) #21
jochen (gone - plz use gerrit)
On 2015/04/28 at 13:05:58, kinuko wrote: > On 2015/04/28 12:01:57, jochen wrote: > > On ...
5 years, 7 months ago (2015-04-28 13:40:35 UTC) #22
kinuko
On 2015/04/28 13:40:35, jochen wrote: > On 2015/04/28 at 13:05:58, kinuko wrote: > > On ...
5 years, 7 months ago (2015-04-28 14:09:38 UTC) #23
jochen (gone - plz use gerrit)
On 2015/04/28 at 14:09:38, kinuko wrote: > On 2015/04/28 13:40:35, jochen wrote: > > On ...
5 years, 7 months ago (2015-04-28 14:12:30 UTC) #24
kinuko
On 2015/04/28 14:12:30, jochen wrote: > On 2015/04/28 at 14:09:38, kinuko wrote: > > On ...
5 years, 7 months ago (2015-04-28 14:32:08 UTC) #26
jochen (gone - plz use gerrit)
On 2015/04/28 at 14:32:08, kinuko wrote: > On 2015/04/28 14:12:30, jochen wrote: > > On ...
5 years, 7 months ago (2015-04-29 09:43:50 UTC) #27
kinuko
On 2015/04/29 09:43:50, jochen wrote: > On 2015/04/28 at 14:32:08, kinuko wrote: > > On ...
5 years, 7 months ago (2015-04-29 10:29:32 UTC) #28
jochen (gone - plz use gerrit)
https://codereview.chromium.org/1072933006/diff/220001/content/renderer/render_thread_impl.cc File content/renderer/render_thread_impl.cc (right): https://codereview.chromium.org/1072933006/diff/220001/content/renderer/render_thread_impl.cc#newcode391 content/renderer/render_thread_impl.cc:391: void RegisterSecureOriginsWhitelist() { this can be moved to chrome ...
5 years, 7 months ago (2015-04-30 07:15:32 UTC) #29
kinuko
https://codereview.chromium.org/1072933006/diff/220001/content/renderer/render_thread_impl.cc File content/renderer/render_thread_impl.cc (right): https://codereview.chromium.org/1072933006/diff/220001/content/renderer/render_thread_impl.cc#newcode391 content/renderer/render_thread_impl.cc:391: void RegisterSecureOriginsWhitelist() { On 2015/04/30 07:15:32, jochen wrote: > ...
5 years, 7 months ago (2015-04-30 08:16:25 UTC) #30
jochen (gone - plz use gerrit)
lgtm
5 years, 7 months ago (2015-04-30 08:17:00 UTC) #31
jww
lgtm, with minor test suggestion. https://codereview.chromium.org/1072933006/diff/240001/chrome/common/secure_origin_whitelist_unittest.cc File chrome/common/secure_origin_whitelist_unittest.cc (right): https://codereview.chromium.org/1072933006/diff/240001/chrome/common/secure_origin_whitelist_unittest.cc#newcode5 chrome/common/secure_origin_whitelist_unittest.cc:5: #include "base/basictypes.h" remove? https://codereview.chromium.org/1072933006/diff/240001/chrome/common/secure_origin_whitelist_unittest.cc#newcode33 ...
5 years, 7 months ago (2015-04-30 18:26:42 UTC) #32
kinuko
Thanks, updated, will be landing. https://codereview.chromium.org/1072933006/diff/240001/chrome/common/secure_origin_whitelist_unittest.cc File chrome/common/secure_origin_whitelist_unittest.cc (right): https://codereview.chromium.org/1072933006/diff/240001/chrome/common/secure_origin_whitelist_unittest.cc#newcode5 chrome/common/secure_origin_whitelist_unittest.cc:5: #include "base/basictypes.h" On 2015/04/30 ...
5 years, 7 months ago (2015-05-01 03:10:57 UTC) #33
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1072933006/260001
5 years, 7 months ago (2015-05-01 03:11:37 UTC) #36
commit-bot: I haz the power
Committed patchset #12 (id:260001)
5 years, 7 months ago (2015-05-01 04:04:31 UTC) #37
commit-bot: I haz the power
5 years, 7 months ago (2015-05-01 04:05:33 UTC) #38
Message was sent while issue was closed.
Patchset 12 (id:??) landed as
https://crrev.com/aaff1f6f8942f714a85a097228dd1e0fb13a36b8
Cr-Commit-Position: refs/heads/master@{#327875}

Powered by Google App Engine
This is Rietveld 408576698