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

Issue 11313018: Prevent webview tags from navigating outside web-safe schemes. (Closed)

Created:
8 years, 1 month ago by Charlie Reis
Modified:
8 years, 1 month ago
CC:
chromium-reviews, joi+watch-content_chromium.org, darin-cc_chromium.org, jam
Visibility:
Public.

Description

Prevent webview tags from navigating outside web-safe schemes. This CL removes protocol handlers and avoids granting capabilities or bindings to webview processes, which prevents navigations to WebUI, extension, and file URLs. Web and data URLs are still permitted. BUG=139397 TEST=Try to visit chrome://settings or other privileged URLs in a <webview>. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=164788

Patch Set 1 #

Patch Set 2 : Fix failing unit tests. #

Patch Set 3 : Remove TODO #

Total comments: 8

Patch Set 4 : Fix review comments #

Total comments: 2

Patch Set 5 : Fix nit #

Unified diffs Side-by-side diffs Delta from patch set Stats (+106 lines, -76 lines) Patch
M chrome/browser/component/navigation_interception/intercept_navigation_resource_throttle.cc View 1 1 chunk +1 line, -4 lines 0 comments Download
M chrome/browser/profiles/profile_impl_io_data.cc View 1 chunk +8 lines, -4 lines 0 comments Download
M content/browser/browser_plugin/browser_plugin_embedder.cc View 1 2 1 chunk +4 lines, -1 line 0 comments Download
M content/browser/browser_plugin/browser_plugin_host_browsertest.cc View 1 chunk +39 lines, -11 lines 0 comments Download
M content/browser/renderer_host/render_view_host_impl.h View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
M content/browser/renderer_host/render_view_host_impl.cc View 1 2 3 12 chunks +45 lines, -27 lines 0 comments Download
M content/browser/web_contents/web_contents_impl.cc View 1 3 chunks +6 lines, -27 lines 0 comments Download
M content/public/browser/render_view_host.h View 1 2 3 4 2 chunks +2 lines, -1 line 0 comments Download

Messages

Total messages: 13 (0 generated)
Charlie Reis
Tom, can you take a look at the approach? Fady, can you take a look ...
8 years, 1 month ago (2012-10-27 00:00:08 UTC) #1
Fady Samuel
Test: LGTM
8 years, 1 month ago (2012-10-27 00:06:01 UTC) #2
Charlie Reis
Tom, I uploaded a new CL since the simpler FilterURL change blew up in unit ...
8 years, 1 month ago (2012-10-27 01:43:41 UTC) #3
Charlie Reis
Also adding Will Chan for profile_impl_io_data.cc. (I was able to skip the Interceptor stuff since ...
8 years, 1 month ago (2012-10-27 01:46:05 UTC) #4
willchan no longer on Chromium
LGTM Btw, all the stuff where you switch passing the render process id to passing ...
8 years, 1 month ago (2012-10-28 07:58:20 UTC) #5
Fady Samuel
Please remove the TODO in BrowserPluginEmbedder::NavigateGuest. Thanks!
8 years, 1 month ago (2012-10-29 00:48:09 UTC) #6
Charlie Reis
On 2012/10/28 07:58:20, willchan wrote: > Btw, all the stuff where you switch passing the ...
8 years, 1 month ago (2012-10-29 16:36:30 UTC) #7
Tom Sepez
LGTM with nits. https://codereview.chromium.org/11313018/diff/16001/chrome/browser/profiles/profile_impl_io_data.cc File chrome/browser/profiles/profile_impl_io_data.cc (right): https://codereview.chromium.org/11313018/diff/16001/chrome/browser/profiles/profile_impl_io_data.cc#newcode490 chrome/browser/profiles/profile_impl_io_data.cc:490: bool is_guest_process = (app_id.find("guest-") != std::string::npos); ...
8 years, 1 month ago (2012-10-29 17:59:08 UTC) #8
Charlie Reis
Thanks, Tom! joth@, can you give an OWNERs review to intercept_navigation_resource_throttle.cc? It's just a method ...
8 years, 1 month ago (2012-10-29 18:18:31 UTC) #9
joth
lgtm https://codereview.chromium.org/11313018/diff/24001/content/public/browser/render_view_host.h File content/public/browser/render_view_host.h (right): https://codereview.chromium.org/11313018/diff/24001/content/public/browser/render_view_host.h#newcode40 content/public/browser/render_view_host.h:40: class RenderViewHostDelegate; nit: may as well add RenderProcessHost ...
8 years, 1 month ago (2012-10-29 19:36:46 UTC) #10
Charlie Reis
Thanks! https://codereview.chromium.org/11313018/diff/24001/content/public/browser/render_view_host.h File content/public/browser/render_view_host.h (right): https://codereview.chromium.org/11313018/diff/24001/content/public/browser/render_view_host.h#newcode40 content/public/browser/render_view_host.h:40: class RenderViewHostDelegate; On 2012/10/29 19:36:46, joth wrote: > ...
8 years, 1 month ago (2012-10-29 19:41:42 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/creis@chromium.org/11313018/19012
8 years, 1 month ago (2012-10-29 19:41:57 UTC) #12
commit-bot: I haz the power
8 years, 1 month ago (2012-10-30 00:20:10 UTC) #13
Change committed as 164788

Powered by Google App Engine
This is Rietveld 408576698