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

Unified Diff: components/policy/core/common/policy_loader_win.cc

Issue 937153003: Document the idiosyncrasies of policy provisioning on Windows. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add missing comma. Created 5 years, 10 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
« no previous file with comments | « no previous file | components/policy/resources/policy_templates.json » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/policy/core/common/policy_loader_win.cc
diff --git a/components/policy/core/common/policy_loader_win.cc b/components/policy/core/common/policy_loader_win.cc
index bfa675cd8270edc9824325fa7f8b3d2c49fe9436..5b6f57fd2ef69b49ff56f5076a198d0ced4f4662 100644
--- a/components/policy/core/common/policy_loader_win.cc
+++ b/components/policy/core/common/policy_loader_win.cc
@@ -75,6 +75,7 @@ const char kExpectedWebStoreUrl[] =
const char kBlockedExtensionPrefix[] = "[BLOCKED]";
// List of policies that are considered only if the user is part of a AD domain.
+// Please document any new additions in policy_templates.json!
const char* kInsecurePolicies[] = {
key::kMetricsReportingEnabled,
key::kDefaultSearchProviderEnabled,
@@ -140,7 +141,7 @@ void FilterUntrustedPolicy(PolicyMap* policy) {
int invalid_policies = 0;
const PolicyMap::Entry* map_entry =
- policy->Get(policy::key::kExtensionInstallForcelist);
+ policy->Get(key::kExtensionInstallForcelist);
if (map_entry && map_entry->value) {
const base::ListValue* policy_list_value = NULL;
if (!map_entry->value->GetAsList(&policy_list_value))
@@ -164,13 +165,13 @@ void FilterUntrustedPolicy(PolicyMap* policy) {
filtered_values->AppendString(entry);
}
if (invalid_policies) {
- policy->Set(policy::key::kExtensionInstallForcelist,
+ policy->Set(key::kExtensionInstallForcelist,
map_entry->level, map_entry->scope,
filtered_values.release(),
map_entry->external_data_fetcher);
- const PolicyDetails* details = policy::GetChromePolicyDetails(
- policy::key::kExtensionInstallForcelist);
+ const PolicyDetails* details = GetChromePolicyDetails(
+ key::kExtensionInstallForcelist);
UMA_HISTOGRAM_SPARSE_SLOWLY("EnterpriseCheck.InvalidPolicies",
details->id);
}
@@ -182,7 +183,7 @@ void FilterUntrustedPolicy(PolicyMap* policy) {
policy->Erase(kInsecurePolicies[i]);
invalid_policies++;
const PolicyDetails* details =
- policy::GetChromePolicyDetails(kInsecurePolicies[i]);
+ GetChromePolicyDetails(kInsecurePolicies[i]);
UMA_HISTOGRAM_SPARSE_SLOWLY("EnterpriseCheck.InvalidPolicies",
details->id);
}
« no previous file with comments | « no previous file | components/policy/resources/policy_templates.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698