diff options
author | yoz@chromium.org <yoz@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-10-03 19:13:26 +0000 |
---|---|---|
committer | yoz@chromium.org <yoz@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-10-03 19:13:26 +0000 |
commit | 9a83ea0929d9d68ce175ce1ac968f6ebcd91152d (patch) | |
tree | 56a91e44f9afca7aa9ff31ede73db256b6fff7c3 /chrome/common/extensions/permissions/permissions_data.cc | |
parent | e2bc92bfd8863ee4d9293d6711a516dade843742 (diff) | |
download | chromium_src-9a83ea0929d9d68ce175ce1ac968f6ebcd91152d.zip chromium_src-9a83ea0929d9d68ce175ce1ac968f6ebcd91152d.tar.gz chromium_src-9a83ea0929d9d68ce175ce1ac968f6ebcd91152d.tar.bz2 |
Refactor PermissionSet to move chrome-specific host checks to ChromeExtensionsClient.
Combine GetChromeSchemeHosts and GetDistinctHostsForDisplay logic for special permission messages for chrome://favicon into GetSpecialHostPermissionWarnings.
BUG=298586
Review URL: https://codereview.chromium.org/25713006
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@226812 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/common/extensions/permissions/permissions_data.cc')
-rw-r--r-- | chrome/common/extensions/permissions/permissions_data.cc | 22 |
1 files changed, 0 insertions, 22 deletions
diff --git a/chrome/common/extensions/permissions/permissions_data.cc b/chrome/common/extensions/permissions/permissions_data.cc index 89ba420..d9e56ef 100644 --- a/chrome/common/extensions/permissions/permissions_data.cc +++ b/chrome/common/extensions/permissions/permissions_data.cc @@ -38,21 +38,6 @@ namespace { PermissionsData::PolicyDelegate* g_policy_delegate = NULL; -bool ContainsManifestForbiddenPermission(const APIPermissionSet& apis, - string16* error) { - CHECK(error); - for (APIPermissionSet::const_iterator iter = apis.begin(); - iter != apis.end(); ++iter) { - if ((*iter)->ManifestEntryForbidden()) { - *error = ErrorUtils::FormatErrorMessageUTF16( - errors::kPermissionNotAllowedInManifest, - (*iter)->info()->name()); - return true; - } - } - return false; -} - // Custom checks for the experimental permission that can't be expressed in // _permission_features.json. bool CanSpecifyExperimentalPermission(const Extension* extension) { @@ -617,13 +602,6 @@ bool PermissionsData::ParsePermissions(Extension* extension, string16* error) { return false; } - if (ContainsManifestForbiddenPermission( - initial_required_permissions_->api_permissions, error) || - ContainsManifestForbiddenPermission( - initial_optional_permissions_->api_permissions, error)) { - return false; - } - return true; } |