Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(708)

Side by Side Diff: chrome/browser/chromeos/policy/device_network_configuration_updater.cc

Issue 148183013: Use per-user nssdb in onc certificate importer (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 6 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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_network_configuration_updater.h" 5 #include "chrome/browser/chromeos/policy/device_network_configuration_updater.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/bind_helpers.h" 8 #include "base/bind_helpers.h"
9 #include "chrome/browser/chromeos/settings/cros_settings.h" 9 #include "chrome/browser/chromeos/settings/cros_settings.h"
10 #include "chromeos/network/managed_network_configuration_handler.h" 10 #include "chromeos/network/managed_network_configuration_handler.h"
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
59 } 59 }
60 60
61 void DeviceNetworkConfigurationUpdater::Init() { 61 void DeviceNetworkConfigurationUpdater::Init() {
62 NetworkConfigurationUpdater::Init(); 62 NetworkConfigurationUpdater::Init();
63 63
64 // Apply the roaming setting initially. 64 // Apply the roaming setting initially.
65 OnDataRoamingSettingChanged(); 65 OnDataRoamingSettingChanged();
66 } 66 }
67 67
68 void DeviceNetworkConfigurationUpdater::ImportCertificates( 68 void DeviceNetworkConfigurationUpdater::ImportCertificates(
69 const base::ListValue& certificates_onc) { 69 const base::ListValue& certificates_onc,
70 certificate_importer_->ImportCertificates( 70 net::NSSCertDatabase* target_nssdb) {
71 certificates_onc, onc_source_, NULL); 71 // Importing CA and server certs from device policy is not allowed, while
72 // importing client is not yet supported (as a system-wide PKCS#11 token to
73 // which they should be imported is not yet available).
74 NOTREACHED();
72 } 75 }
73 76
74 void DeviceNetworkConfigurationUpdater::ApplyNetworkPolicy( 77 void DeviceNetworkConfigurationUpdater::ApplyNetworkPolicy(
75 base::ListValue* network_configs_onc, 78 base::ListValue* network_configs_onc,
76 base::DictionaryValue* global_network_config) { 79 base::DictionaryValue* global_network_config) {
77 network_config_handler_->SetPolicy(onc_source_, 80 network_config_handler_->SetPolicy(onc_source_,
78 std::string() /* no username hash */, 81 std::string() /* no username hash */,
79 *network_configs_onc, 82 *network_configs_onc,
80 *global_network_config); 83 *global_network_config);
81 } 84 }
(...skipping 21 matching lines...) Expand all
103 } else { 106 } else {
104 DCHECK_EQ(trusted_status, 107 DCHECK_EQ(trusted_status,
105 chromeos::CrosSettingsProvider::PERMANENTLY_UNTRUSTED); 108 chromeos::CrosSettingsProvider::PERMANENTLY_UNTRUSTED);
106 // Roaming is disabled as we can't determine the correct setting. 109 // Roaming is disabled as we can't determine the correct setting.
107 } 110 }
108 111
109 network_device_handler_->SetCellularAllowRoaming(data_roaming_setting); 112 network_device_handler_->SetCellularAllowRoaming(data_roaming_setting);
110 } 113 }
111 114
112 } // namespace policy 115 } // namespace policy
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698