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

Unified Diff: chrome/common/extensions/chrome_extensions_client.cc

Issue 226663003: Allow content script insertion on about:-URLs. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove permission warning for about:-scheme Created 6 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: chrome/common/extensions/chrome_extensions_client.cc
diff --git a/chrome/common/extensions/chrome_extensions_client.cc b/chrome/common/extensions/chrome_extensions_client.cc
index a45d4f80e438e41a1e7610779eed2aa1d00e8974..fc5c44b353842335c08e93384955ce081b1a4793 100644
--- a/chrome/common/extensions/chrome_extensions_client.cc
+++ b/chrome/common/extensions/chrome_extensions_client.cc
@@ -98,7 +98,9 @@ void ChromeExtensionsClient::FilterHostPermissions(
messages->insert(PermissionMessage(
PermissionMessage::kFavicon,
l10n_util::GetStringUTF16(IDS_EXTENSION_PROMPT_WARNING_FAVICON)));
- } else {
+ } else if (i->scheme() != content::kAboutScheme) {
+ // Don't warn about the about: scheme, because extensions cannot script
not at google - send to devlin 2014/04/10 21:12:49 can we only support about:blank?
+ // these pages unless they have the permission to edit the frame's origin.
not at google - send to devlin 2014/04/18 16:04:55 @jschuh is the origin of a top-level about:blank "
new_hosts->AddPattern(*i);
}
}

Powered by Google App Engine
This is Rietveld 408576698