| Index: chrome/browser/chromeos/policy/device_policy_decoder_chromeos.cc
|
| diff --git a/chrome/browser/chromeos/policy/device_policy_decoder_chromeos.cc b/chrome/browser/chromeos/policy/device_policy_decoder_chromeos.cc
|
| index 73bb30eb9b79acb747cb1bff65c0d6723e4342ef..b9639750ed4a2e5382f034f3bd06de1facb8259a 100644
|
| --- a/chrome/browser/chromeos/policy/device_policy_decoder_chromeos.cc
|
| +++ b/chrome/browser/chromeos/policy/device_policy_decoder_chromeos.cc
|
| @@ -278,90 +278,6 @@ void DecodeLoginPolicies(const em::ChromeDeviceSettingsProto& policy,
|
| }
|
| }
|
|
|
| -void DecodeKioskPolicies(const em::ChromeDeviceSettingsProto& policy,
|
| - PolicyMap* policies,
|
| - EnterpriseInstallAttributes* install_attributes) {
|
| - // No policies if this is not KIOSK.
|
| - if (install_attributes->GetMode() != DEVICE_MODE_RETAIL_KIOSK)
|
| - return;
|
| -
|
| - if (policy.has_forced_logout_timeouts()) {
|
| - const em::ForcedLogoutTimeoutsProto& container(
|
| - policy.forced_logout_timeouts());
|
| - if (container.has_idle_logout_timeout()) {
|
| - policies->Set(
|
| - key::kDeviceIdleLogoutTimeout,
|
| - POLICY_LEVEL_MANDATORY,
|
| - POLICY_SCOPE_MACHINE,
|
| - DecodeIntegerValue(container.idle_logout_timeout()).release(),
|
| - NULL);
|
| - }
|
| - if (container.has_idle_logout_warning_duration()) {
|
| - policies->Set(key::kDeviceIdleLogoutWarningDuration,
|
| - POLICY_LEVEL_MANDATORY,
|
| - POLICY_SCOPE_MACHINE,
|
| - DecodeIntegerValue(container.idle_logout_warning_duration())
|
| - .release(),
|
| - NULL);
|
| - }
|
| - }
|
| -
|
| - if (policy.has_login_screen_saver()) {
|
| - const em::ScreenSaverProto& container(
|
| - policy.login_screen_saver());
|
| - if (container.has_screen_saver_extension_id()) {
|
| - policies->Set(key::kDeviceLoginScreenSaverId,
|
| - POLICY_LEVEL_MANDATORY,
|
| - POLICY_SCOPE_MACHINE,
|
| - new base::StringValue(
|
| - container.screen_saver_extension_id()),
|
| - NULL);
|
| - }
|
| - if (container.has_screen_saver_timeout()) {
|
| - policies->Set(
|
| - key::kDeviceLoginScreenSaverTimeout,
|
| - POLICY_LEVEL_MANDATORY,
|
| - POLICY_SCOPE_MACHINE,
|
| - DecodeIntegerValue(container.screen_saver_timeout()).release(),
|
| - NULL);
|
| - }
|
| - }
|
| -
|
| - if (policy.has_app_pack()) {
|
| - const em::AppPackProto& container(policy.app_pack());
|
| - base::ListValue* app_pack_list = new base::ListValue();
|
| - for (int i = 0; i < container.app_pack_size(); ++i) {
|
| - const em::AppPackEntryProto& entry(container.app_pack(i));
|
| - if (entry.has_extension_id() && entry.has_update_url()) {
|
| - base::DictionaryValue* dict = new base::DictionaryValue();
|
| - dict->SetString(chromeos::kAppPackKeyExtensionId, entry.extension_id());
|
| - dict->SetString(chromeos::kAppPackKeyUpdateUrl, entry.update_url());
|
| - app_pack_list->Append(dict);
|
| - }
|
| - }
|
| - policies->Set(key::kDeviceAppPack,
|
| - POLICY_LEVEL_MANDATORY,
|
| - POLICY_SCOPE_MACHINE,
|
| - app_pack_list,
|
| - NULL);
|
| - }
|
| -
|
| - if (policy.has_pinned_apps()) {
|
| - const em::PinnedAppsProto& container(policy.pinned_apps());
|
| - base::ListValue* pinned_apps_list = new base::ListValue();
|
| - for (int i = 0; i < container.app_id_size(); ++i) {
|
| - pinned_apps_list->Append(
|
| - new base::StringValue(container.app_id(i)));
|
| - }
|
| -
|
| - policies->Set(key::kPinnedLauncherApps,
|
| - POLICY_LEVEL_RECOMMENDED,
|
| - POLICY_SCOPE_MACHINE,
|
| - pinned_apps_list,
|
| - NULL);
|
| - }
|
| -}
|
| -
|
| void DecodeNetworkPolicies(const em::ChromeDeviceSettingsProto& policy,
|
| PolicyMap* policies,
|
| EnterpriseInstallAttributes* install_attributes) {
|
| @@ -382,7 +298,7 @@ void DecodeNetworkPolicies(const em::ChromeDeviceSettingsProto& policy,
|
|
|
| // Figure out the level. Proxy policy is mandatory in kiosk mode.
|
| PolicyLevel level = POLICY_LEVEL_RECOMMENDED;
|
| - if (install_attributes->GetMode() == DEVICE_MODE_RETAIL_KIOSK)
|
| + if (install_attributes->GetMode() == DEVICE_MODE_LEGACY_RETAIL_MODE)
|
| level = POLICY_LEVEL_MANDATORY;
|
|
|
| if (!proxy_settings->empty()) {
|
| @@ -660,22 +576,6 @@ void DecodeGenericPolicies(const em::ChromeDeviceSettingsProto& policy,
|
| }
|
| }
|
|
|
| - if (policy.has_start_up_urls()) {
|
| - const em::StartUpUrlsProto& container(policy.start_up_urls());
|
| - base::ListValue* urls = new base::ListValue();
|
| - RepeatedPtrField<std::string>::const_iterator entry;
|
| - for (entry = container.start_up_urls().begin();
|
| - entry != container.start_up_urls().end();
|
| - ++entry) {
|
| - urls->Append(new base::StringValue(*entry));
|
| - }
|
| - policies->Set(key::kDeviceStartUpUrls,
|
| - POLICY_LEVEL_MANDATORY,
|
| - POLICY_SCOPE_MACHINE,
|
| - urls,
|
| - NULL);
|
| - }
|
| -
|
| if (policy.has_system_timezone()) {
|
| if (policy.system_timezone().has_timezone()) {
|
| policies->Set(key::kSystemTimezone,
|
| @@ -810,7 +710,6 @@ void DecodeDevicePolicy(const em::ChromeDeviceSettingsProto& policy,
|
|
|
| // Decode the various groups of policies.
|
| DecodeLoginPolicies(policy, policies);
|
| - DecodeKioskPolicies(policy, policies, install_attributes);
|
| DecodeNetworkPolicies(policy, policies, install_attributes);
|
| DecodeReportingPolicies(policy, policies);
|
| DecodeAutoUpdatePolicies(policy, policies);
|
|
|