Commit be4bf460 authored by Roger Tawa's avatar Roger Tawa Committed by Commit Bot

Add chrome policies for content compliance.

Bug: 991553
Change-Id: If5d74661f713101080f75e4baa6a77e981ac0f39
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1742209
Commit-Queue: Roger Tawa <rogerta@chromium.org>
Reviewed-by: default avatarSergey Poromov <poromov@chromium.org>
Cr-Commit-Position: refs/heads/master@{#689452}
parent b4155e28
...@@ -1069,6 +1069,21 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = { ...@@ -1069,6 +1069,21 @@ const PolicyToPreferenceMapEntry kSimplePolicyMap[] = {
{ key::kBrowserSwitcherDelay, { key::kBrowserSwitcherDelay,
browser_switcher::prefs::kDelay, browser_switcher::prefs::kDelay,
base::Value::Type::INTEGER }, base::Value::Type::INTEGER },
{ key::kUnsafeEventsReportingEnabled,
policy_prefs::kUnsafeEventsReportingEnabled,
base::Value::Type::BOOLEAN },
{ key::kDelayDeliveryUntilVerdict,
policy_prefs::kDelayDeliveryUntilVerdict,
base::Value::Type::INTEGER },
{ key::kBlockLargeFileTransfer,
policy_prefs::kBlockLargeFileTransfer,
base::Value::Type::INTEGER },
{ key::kAllowPasswordProtectedFiles,
policy_prefs::kAllowPasswordProtectedFiles,
base::Value::Type::INTEGER },
{ key::kCheckContentCompliance,
policy_prefs::kCheckContentCompliance,
base::Value::Type::INTEGER },
#endif #endif
#if defined(OS_WIN) #if defined(OS_WIN)
{ key::kBrowserSwitcherUseIeSitelist, { key::kBrowserSwitcherUseIeSitelist,
......
...@@ -5021,5 +5021,46 @@ ...@@ -5021,5 +5021,46 @@
"pref_mappings": [ "pref_mappings": [
{ "pref": "safebrowsing.send_files_for_malware_check" } { "pref": "safebrowsing.send_files_for_malware_check" }
] ]
},
"UnsafeEventsReportingEnabled": {
"os": ["win", "linux", "mac"],
"test_policy": { "UnsafeEventsReportingEnabled": false },
"pref_mappings": [ { "pref": "policy.unsafe_events_reporting",
"local_state": true } ]
},
"BlockLargeFileTransfer": {
"os": ["win", "linux", "mac"],
"test_policy": { "BlockLargeFileTransfer": 0 },
"pref_mappings": [ { "pref": "policy.block_large_file_transfers",
"local_state": true } ]
},
"DelayDeliveryUntilVerdict": {
"os": ["win", "linux", "mac"],
"test_policy": { "DelayDeliveryUntilVerdict": 0 },
"pref_mappings": [ { "pref": "policy.delay_delivery_until_verdict",
"local_state": true } ]
},
"AllowPasswordProtectedFiles": {
"os": ["win", "linux", "mac"],
"test_policy": { "AllowPasswordProtectedFiles": 0 },
"pref_mappings": [ { "pref": "policy.allow_password_protected_files",
"local_state": true } ]
},
"CheckContentCompliance": {
"os": ["win", "linux", "mac"],
"test_policy": { "CheckContentCompliance": 0 },
"pref_mappings": [ { "pref": "policy.check_content_compliance",
"local_state": true } ]
},
"DomainsToCheckComplianceOfDownloadedContent": {
},
"DomainsToNotCheckComplianceOfUploadedContent": {
} }
} }
...@@ -183,6 +183,12 @@ void BrowserPolicyConnector::RegisterPrefs(PrefRegistrySimple* registry) { ...@@ -183,6 +183,12 @@ void BrowserPolicyConnector::RegisterPrefs(PrefRegistrySimple* registry) {
policy_prefs::kCloudManagementEnrollmentMandatory, false); policy_prefs::kCloudManagementEnrollmentMandatory, false);
registry->RegisterBooleanPref( registry->RegisterBooleanPref(
policy_prefs::kCloudPolicyOverridesPlatformPolicy, false); policy_prefs::kCloudPolicyOverridesPlatformPolicy, false);
registry->RegisterBooleanPref(policy_prefs::kUnsafeEventsReportingEnabled,
false);
registry->RegisterIntegerPref(policy_prefs::kBlockLargeFileTransfer, 0);
registry->RegisterIntegerPref(policy_prefs::kDelayDeliveryUntilVerdict, 0);
registry->RegisterIntegerPref(policy_prefs::kAllowPasswordProtectedFiles, 0);
registry->RegisterIntegerPref(policy_prefs::kCheckContentCompliance, 0);
} }
} // namespace policy } // namespace policy
...@@ -39,5 +39,24 @@ const char kCloudManagementEnrollmentMandatory[] = ...@@ -39,5 +39,24 @@ const char kCloudManagementEnrollmentMandatory[] =
// machine policy. // machine policy.
const char kCloudPolicyOverridesPlatformPolicy[] = "policy.cloud_override"; const char kCloudPolicyOverridesPlatformPolicy[] = "policy.cloud_override";
// Boolean that indidicates if Chrome reports unsafe events to Google.
const char kUnsafeEventsReportingEnabled[] = "policy.unsafe_events_reporting";
// Integer that specifies if large files are blocked form either uploads or
// downloads or both.
const char kBlockLargeFileTransfer[] = "policy.block_large_file_transfers";
// Integer that specifies if delivery to the user of potentially unsafe data
// is delayed until a verdict about the data is known.
const char kDelayDeliveryUntilVerdict[] = "policy.delay_delivery_until_verdict";
// Integer that specifies if password protected files can be either uploaded
// or downloaded or both.
const char kAllowPasswordProtectedFiles[] =
"policy.allow_password_protected_files";
// Boolean that indidicates if Chrome checks data for content compliance.
const char kCheckContentCompliance[] = "policy.check_content_compliance";
} // namespace policy_prefs } // namespace policy_prefs
} // namespace policy } // namespace policy
...@@ -18,6 +18,11 @@ POLICY_EXPORT extern const char kUrlWhitelist[]; ...@@ -18,6 +18,11 @@ POLICY_EXPORT extern const char kUrlWhitelist[];
POLICY_EXPORT extern const char kUserPolicyRefreshRate[]; POLICY_EXPORT extern const char kUserPolicyRefreshRate[];
POLICY_EXPORT extern const char kCloudManagementEnrollmentMandatory[]; POLICY_EXPORT extern const char kCloudManagementEnrollmentMandatory[];
POLICY_EXPORT extern const char kCloudPolicyOverridesPlatformPolicy[]; POLICY_EXPORT extern const char kCloudPolicyOverridesPlatformPolicy[];
POLICY_EXPORT extern const char kUnsafeEventsReportingEnabled[];
POLICY_EXPORT extern const char kBlockLargeFileTransfer[];
POLICY_EXPORT extern const char kDelayDeliveryUntilVerdict[];
POLICY_EXPORT extern const char kAllowPasswordProtectedFiles[];
POLICY_EXPORT extern const char kCheckContentCompliance[];
} // namespace policy_prefs } // namespace policy_prefs
} // namespace policy } // namespace policy
......
...@@ -17801,6 +17801,13 @@ Called by update_net_error_codes.py.--> ...@@ -17801,6 +17801,13 @@ Called by update_net_error_codes.py.-->
<int value="582" label="DnsOverHttpsMode"/> <int value="582" label="DnsOverHttpsMode"/>
<int value="583" label="SendFilesForMalwareCheck"/> <int value="583" label="SendFilesForMalwareCheck"/>
<int value="584" label="PolicyAtomicGroupsEnabled"/> <int value="584" label="PolicyAtomicGroupsEnabled"/>
<int value="585" label="UnsafeEventsReportingEnabled"/>
<int value="586" label="BlockLargeFileTransfer"/>
<int value="587" label="DelayDeliveryUntilVerdict"/>
<int value="588" label="AllowPasswordProtectedFiles"/>
<int value="589" label="CheckContentCompliance"/>
<int value="590" label="DomainsToCheckComplianceOfDownloadedContent"/>
<int value="591" label="DomainsToNotCheckComplianceOfUploadedContent"/>
</enum> </enum>
<enum name="EnterprisePolicyInvalidations"> <enum name="EnterprisePolicyInvalidations">
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment