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

Side by Side Diff: chrome/renderer/chrome_content_renderer_client.cc

Issue 12621008: chrome-search: should not be display-isolated (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 7 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/common/render_messages.h ('k') | chrome/renderer/searchbox/searchbox.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/renderer/chrome_content_renderer_client.h" 5 #include "chrome/renderer/chrome_content_renderer_client.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 230 matching lines...) Expand 10 before | Expand all | Expand 10 after
241 thread->GetChannel()->set_outgoing_message_filter(LoadExternalIPCFuzzer()); 241 thread->GetChannel()->set_outgoing_message_filter(LoadExternalIPCFuzzer());
242 } 242 }
243 // chrome:, chrome-search:, chrome-devtools:, and chrome-internal: pages 243 // chrome:, chrome-search:, chrome-devtools:, and chrome-internal: pages
244 // should not be accessible by normal content, and should also be unable to 244 // should not be accessible by normal content, and should also be unable to
245 // script anything but themselves (to help limit the damage that a corrupt 245 // script anything but themselves (to help limit the damage that a corrupt
246 // page could cause). 246 // page could cause).
247 WebString chrome_ui_scheme(ASCIIToUTF16(chrome::kChromeUIScheme)); 247 WebString chrome_ui_scheme(ASCIIToUTF16(chrome::kChromeUIScheme));
248 WebSecurityPolicy::registerURLSchemeAsDisplayIsolated(chrome_ui_scheme); 248 WebSecurityPolicy::registerURLSchemeAsDisplayIsolated(chrome_ui_scheme);
249 249
250 WebString chrome_search_scheme(ASCIIToUTF16(chrome::kChromeSearchScheme)); 250 WebString chrome_search_scheme(ASCIIToUTF16(chrome::kChromeSearchScheme));
251 WebSecurityPolicy::registerURLSchemeAsDisplayIsolated(chrome_search_scheme); 251 if (!command_line->HasSwitch(switches::kInstantProcess))
Charlie Reis 2013/03/21 00:08:17 Why would we register this (or the one above) at a
dhollowa 2013/03/21 01:30:19 The one above, chrome:, is linked from external pl
Charlie Reis 2013/03/21 18:06:42 My mistake; I was misreading that.
252 WebSecurityPolicy::registerURLSchemeAsDisplayIsolated(chrome_search_scheme);
252 253
253 WebString dev_tools_scheme(ASCIIToUTF16(chrome::kChromeDevToolsScheme)); 254 WebString dev_tools_scheme(ASCIIToUTF16(chrome::kChromeDevToolsScheme));
254 WebSecurityPolicy::registerURLSchemeAsDisplayIsolated(dev_tools_scheme); 255 WebSecurityPolicy::registerURLSchemeAsDisplayIsolated(dev_tools_scheme);
255 256
256 WebString internal_scheme(ASCIIToUTF16(chrome::kChromeInternalScheme)); 257 WebString internal_scheme(ASCIIToUTF16(chrome::kChromeInternalScheme));
257 WebSecurityPolicy::registerURLSchemeAsDisplayIsolated(internal_scheme); 258 WebSecurityPolicy::registerURLSchemeAsDisplayIsolated(internal_scheme);
258 259
259 #if defined(OS_CHROMEOS) 260 #if defined(OS_CHROMEOS)
260 WebString drive_scheme(ASCIIToUTF16(chrome::kDriveScheme)); 261 WebString drive_scheme(ASCIIToUTF16(chrome::kDriveScheme));
261 WebSecurityPolicy::registerURLSchemeAsLocal(drive_scheme); 262 WebSecurityPolicy::registerURLSchemeAsLocal(drive_scheme);
(...skipping 865 matching lines...) Expand 10 before | Expand all | Expand 10 after
1127 return false; 1128 return false;
1128 1129
1129 if (container->element().shadowHost().isNull()) 1130 if (container->element().shadowHost().isNull())
1130 return false; 1131 return false;
1131 1132
1132 return container->element().shadowHost().tagName().equals( 1133 return container->element().shadowHost().tagName().equals(
1133 WebString::fromUTF8(kWebViewTagName)); 1134 WebString::fromUTF8(kWebViewTagName));
1134 } 1135 }
1135 1136
1136 } // namespace chrome 1137 } // namespace chrome
OLDNEW
« no previous file with comments | « chrome/common/render_messages.h ('k') | chrome/renderer/searchbox/searchbox.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698