From 8440052c7882f61cfde793f687e72717c85e0d8f Mon Sep 17 00:00:00 2001 From: jww Date: Thu, 20 Aug 2015 18:05:47 -0700 Subject: Setup for moving getUserMedia to secure origins only This makes two notable changes: * Removes the browser tests that verify that the getUserMedia permission is not "sticky" on insecure origins. * Moves the addition of the chrome-extension: and chrome-extension-resource: schemes to extensions::Dispatcher. The former is necessary because once getUserMedia is removed from insecure origins, the browser test will (correctly) fail. Thus this is part of a two sided patch. The later is necessary because extension browser tests that use getUserMedia will start failing once the change is made, because the tests use ShellContentRendererClient, which doesn't currently treat chrome-extension: schemes as secure, so getUserMedia will be disallowed by the renderer. By marking the scheme as secure in extensions::Dispatcher instead of in ChromeContentRendererClient::RenderThreadStarted, the schemes will be marked as secure in ShellContentRendererClient as well, so getUserMedia will be allowed in the browser tests. BUG=520765 Review URL: https://codereview.chromium.org/1301653005 Cr-Commit-Position: refs/heads/master@{#344635} --- extensions/shell/renderer/shell_content_renderer_client.cc | 3 --- 1 file changed, 3 deletions(-) (limited to 'extensions/shell') diff --git a/extensions/shell/renderer/shell_content_renderer_client.cc b/extensions/shell/renderer/shell_content_renderer_client.cc index 4ac5cfe..e3fda28 100644 --- a/extensions/shell/renderer/shell_content_renderer_client.cc +++ b/extensions/shell/renderer/shell_content_renderer_client.cc @@ -59,9 +59,6 @@ void ShellContentRendererClient::RenderThreadStarted() { guest_view_container_dispatcher_.reset( new ExtensionsGuestViewContainerDispatcher()); thread->AddObserver(guest_view_container_dispatcher_.get()); - - // TODO(jamescook): Init WebSecurityPolicy for chrome-extension: schemes. - // See ChromeContentRendererClient for details. } void ShellContentRendererClient::RenderFrameCreated( -- cgit v1.1