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

Issue 1507023004: Harden the implementation of '--disable-web-security' (Closed)

Created:
5 years ago by Mike West
Modified:
4 years, 2 months ago
CC:
blink-reviews, blink-reviews-api_chromium.org, blink-reviews-dom_chromium.org, chromium-reviews, creis+watch_chromium.org, darin-cc_chromium.org, dglazkov+blink, eae+blinkwatch, jam, mkwst+moarreviews-renderer_chromium.org, mlamouri+watch-content_chromium.org, nasko+codewatch_chromium.org, rwlbuis, sof
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Harden the implementation of '--disable-web-security' This patch adds a browser-side check that ensures universal access can only be granted if the browser process has the '--disable-web-security' command-line flag. It also weakens the grant given for 'file:' URLs by things like the 'setAllowUniversalAccessFromFileURLs()' WebView API by ensuring that it may only be applied to "local" origins. BUG=327804

Patch Set 1 #

Patch Set 2 : Harder. #

Patch Set 3 : exclude //content/shell #

Total comments: 8

Patch Set 4 : esprehn feedback #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+95 lines, -6 lines) Patch
M content/browser/renderer_host/render_process_host_impl.h View 1 2 3 1 chunk +1 line, -0 lines 0 comments Download
M content/browser/renderer_host/render_process_host_impl.cc View 1 2 3 2 chunks +9 lines, -0 lines 0 comments Download
M content/common/render_process_messages.h View 1 chunk +4 lines, -0 lines 0 comments Download
M content/public/renderer/content_renderer_client.h View 1 2 1 chunk +3 lines, -0 lines 0 comments Download
M content/public/renderer/content_renderer_client.cc View 1 2 1 chunk +4 lines, -0 lines 0 comments Download
M content/renderer/renderer_blink_platform_impl.h View 1 chunk +1 line, -0 lines 0 comments Download
M content/renderer/renderer_blink_platform_impl.cc View 1 2 3 1 chunk +13 lines, -0 lines 0 comments Download
M content/shell/renderer/layout_test/layout_test_content_renderer_client.h View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M content/shell/renderer/layout_test/layout_test_content_renderer_client.cc View 1 2 1 chunk +5 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/dom/Document.cpp View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M third_party/WebKit/Source/platform/weborigin/SecurityOrigin.h View 1 2 3 3 chunks +11 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/platform/weborigin/SecurityOrigin.cpp View 1 2 3 10 chunks +39 lines, -3 lines 0 comments Download
M third_party/WebKit/public/platform/Platform.h View 2 chunks +3 lines, -1 line 1 comment Download
M third_party/WebKit/public/web/WebFrameClient.h View 1 2 3 1 chunk +0 lines, -1 line 1 comment Download

Messages

Total messages: 25 (5 generated)
Mike West
WDYT, Jochen? torne@: FYI. I don't think this will affect Android, as the existing WebView ...
5 years ago (2015-12-09 12:39:42 UTC) #2
Torne
LGTM from WebView's POV. We definitely don't intend to ever allow the equivalent of --disable-web-security ...
5 years ago (2015-12-09 12:55:57 UTC) #3
Mike West
Thanks for the confirmation, torne@! https://codereview.chromium.org/1507023004/diff/40001/third_party/WebKit/Source/platform/weborigin/SecurityOrigin.h File third_party/WebKit/Source/platform/weborigin/SecurityOrigin.h (right): https://codereview.chromium.org/1507023004/diff/40001/third_party/WebKit/Source/platform/weborigin/SecurityOrigin.h#newcode161 third_party/WebKit/Source/platform/weborigin/SecurityOrigin.h:161: // the API which ...
5 years ago (2015-12-09 14:17:49 UTC) #4
Marshall
https://codereview.chromium.org/1507023004/diff/40001/content/renderer/renderer_blink_platform_impl.cc File content/renderer/renderer_blink_platform_impl.cc (right): https://codereview.chromium.org/1507023004/diff/40001/content/renderer/renderer_blink_platform_impl.cc#newcode434 content/renderer/renderer_blink_platform_impl.cc:434: thread->Send(new RenderProcessHostMsg_GetUniversalAccessDisposition( Since the result of this sync IPC ...
5 years ago (2015-12-09 14:20:22 UTC) #6
Mike West
On 2015/12/09 at 14:20:22, marshall wrote: > https://codereview.chromium.org/1507023004/diff/40001/content/renderer/renderer_blink_platform_impl.cc#newcode434 > content/renderer/renderer_blink_platform_impl.cc:434: thread->Send(new RenderProcessHostMsg_GetUniversalAccessDisposition( > Since the ...
5 years ago (2015-12-09 14:53:50 UTC) #7
Marshall
On 2015/12/09 14:53:50, Mike West wrote: > On 2015/12/09 at 14:20:22, marshall wrote: > > ...
5 years ago (2015-12-09 15:09:37 UTC) #8
Mike West
On 2015/12/09 at 15:09:37, marshall wrote: > > *shrug* I think it would be helpful, ...
5 years ago (2015-12-09 17:05:40 UTC) #9
Mike West
On 2015/12/09 at 17:05:40, Mike West wrote: > On 2015/12/09 at 15:09:37, marshall wrote: > ...
5 years ago (2015-12-09 17:06:40 UTC) #10
esprehn
https://codereview.chromium.org/1507023004/diff/40001/content/renderer/renderer_blink_platform_impl.cc File content/renderer/renderer_blink_platform_impl.cc (right): https://codereview.chromium.org/1507023004/diff/40001/content/renderer/renderer_blink_platform_impl.cc#newcode433 content/renderer/renderer_blink_platform_impl.cc:433: if (RenderThread* thread = RenderThread::Get()) { how is it ...
5 years ago (2015-12-10 08:06:44 UTC) #12
commit-bot: I haz the power
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1507023004/60001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1507023004/60001
5 years ago (2015-12-10 13:44:29 UTC) #14
Mike West
On 2015/12/10 at 08:06:44, esprehn wrote: > https://codereview.chromium.org/1507023004/diff/40001/content/renderer/renderer_blink_platform_impl.cc > File content/renderer/renderer_blink_platform_impl.cc (right): > > https://codereview.chromium.org/1507023004/diff/40001/content/renderer/renderer_blink_platform_impl.cc#newcode433 ...
5 years ago (2015-12-10 13:45:17 UTC) #15
commit-bot: I haz the power
Dry run: Try jobs failed on following builders: win_chromium_rel_ng on tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_rel_ng/builds/147768)
5 years ago (2015-12-10 14:53:39 UTC) #17
jochen (gone - plz use gerrit)
https://codereview.chromium.org/1507023004/diff/40001/content/renderer/renderer_blink_platform_impl.cc File content/renderer/renderer_blink_platform_impl.cc (right): https://codereview.chromium.org/1507023004/diff/40001/content/renderer/renderer_blink_platform_impl.cc#newcode434 content/renderer/renderer_blink_platform_impl.cc:434: thread->Send(new RenderProcessHostMsg_GetUniversalAccessDisposition( On 2015/12/09 at 14:20:22, Marshall wrote: > ...
5 years ago (2015-12-10 15:39:33 UTC) #18
esprehn
When are these sync IPCs? Every time you create a new iframe? Please don't add ...
5 years ago (2015-12-11 00:09:54 UTC) #19
Mike West
On 2015/12/10 at 15:39:33, jochen wrote: > https://codereview.chromium.org/1507023004/diff/40001/content/renderer/renderer_blink_platform_impl.cc#newcode434 > content/renderer/renderer_blink_platform_impl.cc:434: thread->Send(new RenderProcessHostMsg_GetUniversalAccessDisposition( > On 2015/12/09 ...
5 years ago (2015-12-11 14:06:17 UTC) #20
Mike West
On 2015/12/11 at 00:09:54, esprehn wrote: > When are these sync IPCs? Every time you ...
5 years ago (2015-12-11 14:11:42 UTC) #21
esprehn
Doing another sync up for every document is not acceptable. This needs to be passed ...
5 years ago (2015-12-11 16:23:13 UTC) #22
esprehn
Doing another sync up for every document is not acceptable. This needs to be passed ...
5 years ago (2015-12-11 16:29:07 UTC) #23
jochen (gone - plz use gerrit)
On 2015/12/11 at 14:06:17, mkwst wrote: > On 2015/12/10 at 15:39:33, jochen wrote: > > ...
5 years ago (2015-12-14 12:09:25 UTC) #24
Torne
4 years, 3 months ago (2016-09-13 15:03:58 UTC) #25
Are we going ahead with this, or should the CL be closed?

Powered by Google App Engine
This is Rietveld 408576698