summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjoaodasilva@chromium.org <joaodasilva@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-04-16 19:13:35 +0000
committerjoaodasilva@chromium.org <joaodasilva@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-04-16 19:13:35 +0000
commita01240b42069a0b0a04dc983c1492837b4fca759 (patch)
tree9ccaac903f2f83ab585d5ffe5ab0b6a3cfc46e67
parentb0c126670ba9d1216210fa253b593e6caeac331a (diff)
downloadchromium_src-a01240b42069a0b0a04dc983c1492837b4fca759.zip
chromium_src-a01240b42069a0b0a04dc983c1492837b4fca759.tar.gz
chromium_src-a01240b42069a0b0a04dc983c1492837b4fca759.tar.bz2
Display the extension id and name when its installation is refused by policy.
BUG=123381 TEST=Try to install a blacklisted extension. The error message and the log detail the extension name and id. Review URL: http://codereview.chromium.org/10097014 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@132437 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--chrome/app/generated_resources.grd2
-rw-r--r--chrome/browser/extensions/crx_installer.cc6
2 files changed, 5 insertions, 3 deletions
diff --git a/chrome/app/generated_resources.grd b/chrome/app/generated_resources.grd
index a365f8c..948dbe1 100644
--- a/chrome/app/generated_resources.grd
+++ b/chrome/app/generated_resources.grd
@@ -4335,7 +4335,7 @@ Update checks have repeatedly failed for the extension "<ph name="EXTENSION_NAME
This extension is blacklisted.
</message>
<message name="IDS_EXTENSION_CANT_INSTALL_POLICY_BLACKLIST" desc="Error message when a user tries to install an extension that is blacklisted by administrator policy.">
- This extension is blacklisted by admin policy.
+ <ph name="EXTENSION_NAME">$1<ex>Google Talk</ex></ph> (extension ID "<ph name="EXTENSION_ID">$2<ex>nckgahadagoaajjgafhacjanaoiihapd</ex></ph>") is blacklisted by the administrator.
</message>
<message name="IDS_EXTENSION_MOVE_DIRECTORY_TO_PROFILE_FAILED" desc="">
Could not move extension directory into profile.
diff --git a/chrome/browser/extensions/crx_installer.cc b/chrome/browser/extensions/crx_installer.cc
index 32f14b8..d3262db 100644
--- a/chrome/browser/extensions/crx_installer.cc
+++ b/chrome/browser/extensions/crx_installer.cc
@@ -350,8 +350,10 @@ void CrxInstaller::ConfirmInstall() {
if (!frontend_weak_->extension_prefs()->IsExtensionAllowedByPolicy(
extension_->id(), install_source_)) {
- ReportFailureFromUIThread(
- l10n_util::GetStringUTF16(IDS_EXTENSION_CANT_INSTALL_POLICY_BLACKLIST));
+ ReportFailureFromUIThread(l10n_util::GetStringFUTF16(
+ IDS_EXTENSION_CANT_INSTALL_POLICY_BLACKLIST,
+ UTF8ToUTF16(extension_->name()),
+ UTF8ToUTF16(extension_->id())));
return;
}