| 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 330 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 341 POLICY_LEVEL_MANDATORY, | 341 POLICY_LEVEL_MANDATORY, |
| 342 POLICY_SCOPE_MACHINE, | 342 POLICY_SCOPE_MACHINE, |
| 343 Value::CreateBooleanValue(container.report_boot_mode())); | 343 Value::CreateBooleanValue(container.report_boot_mode())); |
| 344 } | 344 } |
| 345 if (container.has_report_location()) { | 345 if (container.has_report_location()) { |
| 346 policies->Set(key::kReportDeviceLocation, | 346 policies->Set(key::kReportDeviceLocation, |
| 347 POLICY_LEVEL_MANDATORY, | 347 POLICY_LEVEL_MANDATORY, |
| 348 POLICY_SCOPE_MACHINE, | 348 POLICY_SCOPE_MACHINE, |
| 349 Value::CreateBooleanValue(container.report_location())); | 349 Value::CreateBooleanValue(container.report_location())); |
| 350 } | 350 } |
| 351 if (container.has_report_network_interfaces()) { |
| 352 policies->Set(key::kReportDeviceNetworkInterfaces, |
| 353 POLICY_LEVEL_MANDATORY, |
| 354 POLICY_SCOPE_MACHINE, |
| 355 Value::CreateBooleanValue( |
| 356 container.report_network_interfaces())); |
| 357 } |
| 351 } | 358 } |
| 352 } | 359 } |
| 353 | 360 |
| 354 void DecodeAutoUpdatePolicies(const em::ChromeDeviceSettingsProto& policy, | 361 void DecodeAutoUpdatePolicies(const em::ChromeDeviceSettingsProto& policy, |
| 355 PolicyMap* policies) { | 362 PolicyMap* policies) { |
| 356 if (policy.has_release_channel()) { | 363 if (policy.has_release_channel()) { |
| 357 const em::ReleaseChannelProto& container(policy.release_channel()); | 364 const em::ReleaseChannelProto& container(policy.release_channel()); |
| 358 if (container.has_release_channel()) { | 365 if (container.has_release_channel()) { |
| 359 std::string channel(container.release_channel()); | 366 std::string channel(container.release_channel()); |
| 360 policies->Set(key::kChromeOsReleaseChannel, | 367 policies->Set(key::kChromeOsReleaseChannel, |
| (...skipping 227 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 588 DecodeLoginPolicies(policy, policies); | 595 DecodeLoginPolicies(policy, policies); |
| 589 DecodeKioskPolicies(policy, policies, install_attributes); | 596 DecodeKioskPolicies(policy, policies, install_attributes); |
| 590 DecodeNetworkPolicies(policy, policies, install_attributes); | 597 DecodeNetworkPolicies(policy, policies, install_attributes); |
| 591 DecodeReportingPolicies(policy, policies); | 598 DecodeReportingPolicies(policy, policies); |
| 592 DecodeAutoUpdatePolicies(policy, policies); | 599 DecodeAutoUpdatePolicies(policy, policies); |
| 593 DecodeAccessibilityPolicies(policy, policies); | 600 DecodeAccessibilityPolicies(policy, policies); |
| 594 DecodeGenericPolicies(policy, policies); | 601 DecodeGenericPolicies(policy, policies); |
| 595 } | 602 } |
| 596 | 603 |
| 597 } // namespace policy | 604 } // namespace policy |
| OLD | NEW |