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

Side by Side Diff: chrome/browser/chromeos/policy/network_configuration_updater_impl.h

Issue 20041002: Make CertificateHandler a proper interface of CertificateImporter. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Addressed comments. Created 7 years, 5 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 (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 #ifndef CHROME_BROWSER_CHROMEOS_POLICY_NETWORK_CONFIGURATION_UPDATER_IMPL_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_POLICY_NETWORK_CONFIGURATION_UPDATER_IMPL_H_
6 #define CHROME_BROWSER_CHROMEOS_POLICY_NETWORK_CONFIGURATION_UPDATER_IMPL_H_ 6 #define CHROME_BROWSER_CHROMEOS_POLICY_NETWORK_CONFIGURATION_UPDATER_IMPL_H_
7 7
8 #include "chrome/browser/chromeos/policy/network_configuration_updater.h" 8 #include "chrome/browser/chromeos/policy/network_configuration_updater.h"
9 #include "chrome/browser/policy/policy_service.h" 9 #include "chrome/browser/policy/policy_service.h"
10 #include "chromeos/network/onc/onc_constants.h" 10 #include "chromeos/network/onc/onc_constants.h"
11 11
12 namespace base { 12 namespace base {
13 class Value; 13 class Value;
14 } 14 }
15 15
16 namespace chromeos { 16 namespace chromeos {
17 class CertificateHandler; 17 namespace onc {
18 class CertificateImporter;
19 }
18 } 20 }
19 21
20 namespace policy { 22 namespace policy {
21 23
22 class PolicyMap; 24 class PolicyMap;
23 25
24 // This implementation pushes policies to the 26 // This implementation pushes policies to the
25 // ManagedNetworkConfigurationHandler. User policies are only pushed after 27 // ManagedNetworkConfigurationHandler. User policies are only pushed after
26 // OnUserPolicyInitialized() was called. 28 // OnUserPolicyInitialized() was called.
27 class NetworkConfigurationUpdaterImpl : public NetworkConfigurationUpdater, 29 class NetworkConfigurationUpdaterImpl : public NetworkConfigurationUpdater,
28 public PolicyService::Observer { 30 public PolicyService::Observer {
29 public: 31 public:
30 NetworkConfigurationUpdaterImpl( 32 NetworkConfigurationUpdaterImpl(
31 PolicyService* device_policy_service, 33 PolicyService* device_policy_service,
32 scoped_ptr<chromeos::CertificateHandler> certificate_handler); 34 scoped_ptr<chromeos::onc::CertificateImporter> certificate_importer);
33 virtual ~NetworkConfigurationUpdaterImpl(); 35 virtual ~NetworkConfigurationUpdaterImpl();
34 36
35 // NetworkConfigurationUpdater overrides. 37 // NetworkConfigurationUpdater overrides.
36 virtual void SetUserPolicyService( 38 virtual void SetUserPolicyService(
37 bool allow_trusted_certs_from_policy, 39 bool allow_trusted_certs_from_policy,
38 const std::string& hashed_username, 40 const std::string& hashed_username,
39 PolicyService* user_policy_service) OVERRIDE; 41 PolicyService* user_policy_service) OVERRIDE;
40 42
41 virtual void UnsetUserPolicyService() OVERRIDE; 43 virtual void UnsetUserPolicyService() OVERRIDE;
42 44
(...skipping 19 matching lines...) Expand all
62 64
63 // Used to retrieve user policies. 65 // Used to retrieve user policies.
64 PolicyService* user_policy_service_; 66 PolicyService* user_policy_service_;
65 67
66 // Used to retrieve device policies. 68 // Used to retrieve device policies.
67 PolicyService* device_policy_service_; 69 PolicyService* device_policy_service_;
68 70
69 // User hash of the user that the user policy applies to. 71 // User hash of the user that the user policy applies to.
70 std::string hashed_username_; 72 std::string hashed_username_;
71 73
72 scoped_ptr<chromeos::CertificateHandler> certificate_handler_; 74 scoped_ptr<chromeos::onc::CertificateImporter> certificate_importer_;
73 75
74 DISALLOW_COPY_AND_ASSIGN(NetworkConfigurationUpdaterImpl); 76 DISALLOW_COPY_AND_ASSIGN(NetworkConfigurationUpdaterImpl);
75 }; 77 };
76 78
77 } // namespace policy 79 } // namespace policy
78 80
79 #endif // CHROME_BROWSER_CHROMEOS_POLICY_NETWORK_CONFIGURATION_UPDATER_IMPL_H_ 81 #endif // CHROME_BROWSER_CHROMEOS_POLICY_NETWORK_CONFIGURATION_UPDATER_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698