| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/policy/configuration_policy_pref_store.h" | 5 #include "chrome/browser/policy/configuration_policy_pref_store.h" |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/lazy_instance.h" | 8 #include "base/lazy_instance.h" |
| 9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 #include "base/path_service.h" | 10 #include "base/path_service.h" |
| (...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 183 { Value::TYPE_BOOLEAN, kPolicyDisableAuthNegotiateCnameLookup, | 183 { Value::TYPE_BOOLEAN, kPolicyDisableAuthNegotiateCnameLookup, |
| 184 prefs::kDisableAuthNegotiateCnameLookup }, | 184 prefs::kDisableAuthNegotiateCnameLookup }, |
| 185 { Value::TYPE_BOOLEAN, kPolicyEnableAuthNegotiatePort, | 185 { Value::TYPE_BOOLEAN, kPolicyEnableAuthNegotiatePort, |
| 186 prefs::kEnableAuthNegotiatePort }, | 186 prefs::kEnableAuthNegotiatePort }, |
| 187 { Value::TYPE_STRING, kPolicyAuthServerWhitelist, | 187 { Value::TYPE_STRING, kPolicyAuthServerWhitelist, |
| 188 prefs::kAuthServerWhitelist }, | 188 prefs::kAuthServerWhitelist }, |
| 189 { Value::TYPE_STRING, kPolicyAuthNegotiateDelegateWhitelist, | 189 { Value::TYPE_STRING, kPolicyAuthNegotiateDelegateWhitelist, |
| 190 prefs::kAuthNegotiateDelegateWhitelist }, | 190 prefs::kAuthNegotiateDelegateWhitelist }, |
| 191 { Value::TYPE_STRING, kPolicyGSSAPILibraryName, | 191 { Value::TYPE_STRING, kPolicyGSSAPILibraryName, |
| 192 prefs::kGSSAPILibraryName }, | 192 prefs::kGSSAPILibraryName }, |
| 193 { Value::TYPE_BOOLEAN, kPolicyDisable3DAPIs, |
| 194 prefs::kDisable3DAPIs }, |
| 193 | 195 |
| 194 #if defined(OS_CHROMEOS) | 196 #if defined(OS_CHROMEOS) |
| 195 { Value::TYPE_BOOLEAN, kPolicyChromeOsLockOnIdleSuspend, | 197 { Value::TYPE_BOOLEAN, kPolicyChromeOsLockOnIdleSuspend, |
| 196 prefs::kEnableScreenLock }, | 198 prefs::kEnableScreenLock }, |
| 197 #endif | 199 #endif |
| 198 }; | 200 }; |
| 199 | 201 |
| 200 const ConfigurationPolicyPrefStore::PolicyToPreferenceMapEntry | 202 const ConfigurationPolicyPrefStore::PolicyToPreferenceMapEntry |
| 201 ConfigurationPolicyPrefStore::kDefaultSearchPolicyMap[] = { | 203 ConfigurationPolicyPrefStore::kDefaultSearchPolicyMap[] = { |
| 202 { Value::TYPE_BOOLEAN, kPolicyDefaultSearchProviderEnabled, | 204 { Value::TYPE_BOOLEAN, kPolicyDefaultSearchProviderEnabled, |
| (...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 303 { kPolicyDisableAuthNegotiateCnameLookup, Value::TYPE_BOOLEAN, | 305 { kPolicyDisableAuthNegotiateCnameLookup, Value::TYPE_BOOLEAN, |
| 304 key::kDisableAuthNegotiateCnameLookup }, | 306 key::kDisableAuthNegotiateCnameLookup }, |
| 305 { kPolicyEnableAuthNegotiatePort, Value::TYPE_BOOLEAN, | 307 { kPolicyEnableAuthNegotiatePort, Value::TYPE_BOOLEAN, |
| 306 key::kEnableAuthNegotiatePort }, | 308 key::kEnableAuthNegotiatePort }, |
| 307 { kPolicyAuthServerWhitelist, Value::TYPE_STRING, | 309 { kPolicyAuthServerWhitelist, Value::TYPE_STRING, |
| 308 key::kAuthServerWhitelist }, | 310 key::kAuthServerWhitelist }, |
| 309 { kPolicyAuthNegotiateDelegateWhitelist, Value::TYPE_STRING, | 311 { kPolicyAuthNegotiateDelegateWhitelist, Value::TYPE_STRING, |
| 310 key::kAuthNegotiateDelegateWhitelist }, | 312 key::kAuthNegotiateDelegateWhitelist }, |
| 311 { kPolicyGSSAPILibraryName, Value::TYPE_STRING, | 313 { kPolicyGSSAPILibraryName, Value::TYPE_STRING, |
| 312 key::kGSSAPILibraryName }, | 314 key::kGSSAPILibraryName }, |
| 315 { kPolicyDisable3DAPIs, Value::TYPE_BOOLEAN, |
| 316 key::kDisable3DAPIs }, |
| 313 | 317 |
| 314 #if defined(OS_CHROMEOS) | 318 #if defined(OS_CHROMEOS) |
| 315 { kPolicyChromeOsLockOnIdleSuspend, Value::TYPE_BOOLEAN, | 319 { kPolicyChromeOsLockOnIdleSuspend, Value::TYPE_BOOLEAN, |
| 316 key::kChromeOsLockOnIdleSuspend }, | 320 key::kChromeOsLockOnIdleSuspend }, |
| 317 #endif | 321 #endif |
| 318 }; | 322 }; |
| 319 | 323 |
| 320 static ConfigurationPolicyProvider::PolicyDefinitionList policy_list = { | 324 static ConfigurationPolicyProvider::PolicyDefinitionList policy_list = { |
| 321 entries, | 325 entries, |
| 322 entries + arraysize(entries), | 326 entries + arraysize(entries), |
| (...skipping 344 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 667 std::string()); | 671 std::string()); |
| 668 return; | 672 return; |
| 669 } | 673 } |
| 670 } | 674 } |
| 671 // Required entries are not there. Remove any related entries. | 675 // Required entries are not there. Remove any related entries. |
| 672 RemovePreferencesOfMap(kDefaultSearchPolicyMap, | 676 RemovePreferencesOfMap(kDefaultSearchPolicyMap, |
| 673 arraysize(kDefaultSearchPolicyMap)); | 677 arraysize(kDefaultSearchPolicyMap)); |
| 674 } | 678 } |
| 675 | 679 |
| 676 } // namespace policy | 680 } // namespace policy |
| OLD | NEW |