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

Unified Diff: extensions/common/permissions/permissions_data.h

Issue 1140173003: Allow whitelisted content scripts to be injected in WebViews. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@document_has_focus
Patch Set: Use PermissionsData to check whitelist Created 5 years, 7 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: extensions/common/permissions/permissions_data.h
diff --git a/extensions/common/permissions/permissions_data.h b/extensions/common/permissions/permissions_data.h
index 6a84566dc1cc5de553ea34dc1eb7c59ca72a5603..56e6ab40d6d606a057f595985bd83543daca8dae 100644
--- a/extensions/common/permissions/permissions_data.h
+++ b/extensions/common/permissions/permissions_data.h
@@ -60,6 +60,10 @@ class PermissionsData {
PermissionsData(const Extension* extension);
virtual ~PermissionsData();
+ // Returns true if the extension id is on the whitelist of extensions
+ // that can script all pages.
+ static bool IsExtensionIdWhitelisted(const std::string& extension_id);
+
// Returns true if the extension is a COMPONENT extension or is on the
// whitelist of extensions that can script all pages.
static bool CanExecuteScriptEverywhere(const Extension* extension);

Powered by Google App Engine
This is Rietveld 408576698