Chromium Code Reviews| OLD | NEW |
|---|---|
| 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 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_SUPERVISED_USER_MANAGER_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_SUPERVISED_USER_MANAGER_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_SUPERVISED_USER_MANAGER_H_ | 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_SUPERVISED_USER_MANAGER_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| 11 #include "base/strings/string16.h" | 11 #include "base/strings/string16.h" |
| 12 | 12 |
| 13 class PrefRegistrySimple; | 13 class PrefRegistrySimple; |
| 14 | 14 |
| 15 namespace chromeos { | 15 namespace chromeos { |
| 16 | 16 |
| 17 class User; | 17 class User; |
| 18 class SupervisedUserAuthentication; | |
| 19 | |
| 20 extern const char kSchemaVersion[]; | |
| 21 extern const char kPasswordVersion[]; | |
|
Nikita (slow)
2013/12/09 16:42:16
nit: Rename to revision?
Denis Kuznetsov (DE-MUC)
2013/12/12 19:45:24
Done.
| |
| 22 extern const char kSalt[]; | |
| 23 extern const char kEncryptedPassword[]; | |
| 18 | 24 |
| 19 // Base class for SupervisedUserManagerImpl - provides a mechanism for getting | 25 // Base class for SupervisedUserManagerImpl - provides a mechanism for getting |
| 20 // and setting specific values for supervised users, as well as additional | 26 // and setting specific values for supervised users, as well as additional |
| 21 // lookup methods that make sense only for supervised users. | 27 // lookup methods that make sense only for supervised users. |
| 22 class SupervisedUserManager { | 28 class SupervisedUserManager { |
| 23 public: | 29 public: |
| 24 // Registers user manager preferences. | 30 // Registers user manager preferences. |
| 25 static void RegisterPrefs(PrefRegistrySimple* registry); | 31 static void RegisterPrefs(PrefRegistrySimple* registry); |
| 26 | 32 |
| 27 SupervisedUserManager() {} | 33 SupervisedUserManager() {} |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 72 | 78 |
| 73 // Create a record about starting supervised user creation transaction. | 79 // Create a record about starting supervised user creation transaction. |
| 74 virtual void StartCreationTransaction(const string16& display_name) = 0; | 80 virtual void StartCreationTransaction(const string16& display_name) = 0; |
| 75 | 81 |
| 76 // Add user id to supervised user creation transaction record. | 82 // Add user id to supervised user creation transaction record. |
| 77 virtual void SetCreationTransactionUserId(const std::string& user_id) = 0; | 83 virtual void SetCreationTransactionUserId(const std::string& user_id) = 0; |
| 78 | 84 |
| 79 // Remove locally managed user creation transaction record. | 85 // Remove locally managed user creation transaction record. |
| 80 virtual void CommitCreationTransaction() = 0; | 86 virtual void CommitCreationTransaction() = 0; |
| 81 | 87 |
| 88 // Return object that handles specifics of supervised user authentication. | |
| 89 virtual SupervisedUserAuthentication* GetSupervisedUserAuthentication() = 0; | |
|
Nikita (slow)
2013/12/09 16:42:16
nit: I think this may be renamed to GetAuthenticat
Denis Kuznetsov (DE-MUC)
2013/12/12 19:45:24
Done.
| |
| 90 | |
| 91 // Fill |result| with public password-specific data for |user_id| from Local | |
| 92 // State. | |
| 93 virtual void GetPasswordInformation(const std::string& user_id, | |
| 94 base::DictionaryValue* result) = 0; | |
| 95 // Stores public password-specific data from |password_info| for |user_id| in | |
|
Bernhard Bauer
2013/12/11 14:46:43
Nit: newline before this line.
Denis Kuznetsov (DE-MUC)
2013/12/12 19:45:24
Done.
| |
| 96 // Local State. | |
| 97 virtual void SetPasswordInformation( | |
| 98 const std::string& user_id, | |
| 99 const base::DictionaryValue* password_info) = 0; | |
| 100 | |
| 82 private: | 101 private: |
| 83 DISALLOW_COPY_AND_ASSIGN(SupervisedUserManager); | 102 DISALLOW_COPY_AND_ASSIGN(SupervisedUserManager); |
| 84 }; | 103 }; |
| 85 | 104 |
| 86 } // namespace chromeos | 105 } // namespace chromeos |
| 87 | 106 |
| 88 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_SUPERVISED_USER_MANAGER_H_ | 107 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_SUPERVISED_USER_MANAGER_H_ |
| OLD | NEW |