OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/chromeos/policy/device_policy_decoder_chromeos.h" | 5 #include "chrome/browser/chromeos/policy/device_policy_decoder_chromeos.h" |
6 | 6 |
7 #include <limits> | 7 #include <limits> |
8 | 8 |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
10 #include "base/values.h" | 10 #include "base/values.h" |
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
137 if (entry->kiosk_app().has_app_id()) { | 137 if (entry->kiosk_app().has_app_id()) { |
138 entry_dict->SetStringWithoutPathExpansion( | 138 entry_dict->SetStringWithoutPathExpansion( |
139 chromeos::kAccountsPrefDeviceLocalAccountsKeyKioskAppId, | 139 chromeos::kAccountsPrefDeviceLocalAccountsKeyKioskAppId, |
140 entry->kiosk_app().app_id()); | 140 entry->kiosk_app().app_id()); |
141 } | 141 } |
142 if (entry->kiosk_app().has_update_url()) { | 142 if (entry->kiosk_app().has_update_url()) { |
143 entry_dict->SetStringWithoutPathExpansion( | 143 entry_dict->SetStringWithoutPathExpansion( |
144 chromeos::kAccountsPrefDeviceLocalAccountsKeyKioskAppUpdateURL, | 144 chromeos::kAccountsPrefDeviceLocalAccountsKeyKioskAppUpdateURL, |
145 entry->kiosk_app().update_url()); | 145 entry->kiosk_app().update_url()); |
146 } | 146 } |
147 } else if (entry->has_id()) { | 147 } else if (entry->has_deprecated_public_session_id()) { |
148 // Deprecated public session specification. | 148 // Deprecated public session specification. |
149 entry_dict->SetStringWithoutPathExpansion( | 149 entry_dict->SetStringWithoutPathExpansion( |
150 chromeos::kAccountsPrefDeviceLocalAccountsKeyId, entry->id()); | 150 chromeos::kAccountsPrefDeviceLocalAccountsKeyId, |
| 151 entry->deprecated_public_session_id()); |
151 entry_dict->SetIntegerWithoutPathExpansion( | 152 entry_dict->SetIntegerWithoutPathExpansion( |
152 chromeos::kAccountsPrefDeviceLocalAccountsKeyType, | 153 chromeos::kAccountsPrefDeviceLocalAccountsKeyType, |
153 chromeos::DEVICE_LOCAL_ACCOUNT_TYPE_PUBLIC_SESSION); | 154 chromeos::DEVICE_LOCAL_ACCOUNT_TYPE_PUBLIC_SESSION); |
154 } | 155 } |
155 account_list->Append(entry_dict.release()); | 156 account_list->Append(entry_dict.release()); |
156 } | 157 } |
157 policies->Set(key::kDeviceLocalAccounts, | 158 policies->Set(key::kDeviceLocalAccounts, |
158 POLICY_LEVEL_MANDATORY, | 159 POLICY_LEVEL_MANDATORY, |
159 POLICY_SCOPE_MACHINE, | 160 POLICY_SCOPE_MACHINE, |
160 account_list.release()); | 161 account_list.release()); |
(...skipping 365 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
526 // Decode the various groups of policies. | 527 // Decode the various groups of policies. |
527 DecodeLoginPolicies(policy, policies); | 528 DecodeLoginPolicies(policy, policies); |
528 DecodeKioskPolicies(policy, policies, install_attributes); | 529 DecodeKioskPolicies(policy, policies, install_attributes); |
529 DecodeNetworkPolicies(policy, policies, install_attributes); | 530 DecodeNetworkPolicies(policy, policies, install_attributes); |
530 DecodeReportingPolicies(policy, policies); | 531 DecodeReportingPolicies(policy, policies); |
531 DecodeAutoUpdatePolicies(policy, policies); | 532 DecodeAutoUpdatePolicies(policy, policies); |
532 DecodeGenericPolicies(policy, policies); | 533 DecodeGenericPolicies(policy, policies); |
533 } | 534 } |
534 | 535 |
535 } // namespace policy | 536 } // namespace policy |
OLD | NEW |