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

Unified Diff: chrome/browser/chromeos/extensions/extension_tab_util_delegate_chromeos.cc

Issue 2858643002: PS - Filtering activeTab URL (Closed)
Patch Set: Created 3 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/browser/chromeos/extensions/extension_tab_util_delegate_chromeos.cc
diff --git a/chrome/browser/chromeos/extensions/extension_tab_util_delegate_chromeos.cc b/chrome/browser/chromeos/extensions/extension_tab_util_delegate_chromeos.cc
index 3dc599509285136337afc6e214496b45fbe993bf..7220e2c7265c861e5a8ad1b6a713c8a33bcf97eb 100644
--- a/chrome/browser/chromeos/extensions/extension_tab_util_delegate_chromeos.cc
+++ b/chrome/browser/chromeos/extensions/extension_tab_util_delegate_chromeos.cc
@@ -7,6 +7,7 @@
#include <string>
#include "base/memory/ptr_util.h"
+#include "chrome/browser/chromeos/extensions/device_local_account_management_policy_provider.h"
#include "chrome/browser/profiles/profiles_state.h"
#include "chrome/common/extensions/api/tabs.h"
#include "url/gurl.h"
@@ -18,10 +19,11 @@ ExtensionTabUtilDelegateChromeOS::ExtensionTabUtilDelegateChromeOS() {}
ExtensionTabUtilDelegateChromeOS::~ExtensionTabUtilDelegateChromeOS() {}
void ExtensionTabUtilDelegateChromeOS::ScrubTabForExtension(
- const Extension* extension,
- content::WebContents* contents,
+ const std::string& extension_id,
api::tabs::Tab* tab) {
- if (!profiles::IsPublicSession() || !tab->url) {
+ if (!profiles::IsPublicSession() || !tab->url ||
+ chromeos::DeviceLocalAccountManagementPolicyProvider::IsWhitelisted(
+ extension_id)) {
return;
}
// Scrub URL down to the origin (security reasons inside Public Sessions).

Powered by Google App Engine
This is Rietveld 408576698