OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_SESSION_USER_SESSION_MANAGER_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_SESSION_USER_SESSION_MANAGER_H_ |
6 #define CHROME_BROWSER_CHROMEOS_LOGIN_SESSION_USER_SESSION_MANAGER_H_ | 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_SESSION_USER_SESSION_MANAGER_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
91 // and notifies observers. | 91 // and notifies observers. |
92 void RestoreActiveSessions(); | 92 void RestoreActiveSessions(); |
93 | 93 |
94 // Returns true iff browser has been restarted after crash and UserManager | 94 // Returns true iff browser has been restarted after crash and UserManager |
95 // finished restoring user sessions. | 95 // finished restoring user sessions. |
96 bool UserSessionsRestored() const; | 96 bool UserSessionsRestored() const; |
97 | 97 |
98 // Initialize RLZ. | 98 // Initialize RLZ. |
99 void InitRlz(Profile* profile); | 99 void InitRlz(Profile* profile); |
100 | 100 |
| 101 // Get the NSS cert database for the user represented with |profile| |
| 102 // and start certificate loader with it. |
| 103 void InitializeCerts(Profile* profile); |
| 104 |
101 // TODO(nkostylev): Drop these methods once LoginUtilsImpl::AttemptRestart() | 105 // TODO(nkostylev): Drop these methods once LoginUtilsImpl::AttemptRestart() |
102 // is migrated. | 106 // is migrated. |
103 OAuth2LoginManager::SessionRestoreStrategy GetSigninSessionRestoreStrategy(); | 107 OAuth2LoginManager::SessionRestoreStrategy GetSigninSessionRestoreStrategy(); |
104 bool exit_after_session_restore() { return exit_after_session_restore_; } | 108 bool exit_after_session_restore() { return exit_after_session_restore_; } |
105 void set_exit_after_session_restore(bool value) { | 109 void set_exit_after_session_restore(bool value) { |
106 exit_after_session_restore_ = value; | 110 exit_after_session_restore_ = value; |
107 } | 111 } |
108 | 112 |
109 // Invoked when the user is logging in for the first time, or is logging in to | 113 // Invoked when the user is logging in for the first time, or is logging in to |
110 // an ephemeral session type, such as guest or a public session. | 114 // an ephemeral session type, such as guest or a public session. |
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
192 // OAuthLoginManager. | 196 // OAuthLoginManager. |
193 void InitSessionRestoreStrategy(); | 197 void InitSessionRestoreStrategy(); |
194 | 198 |
195 // Restores GAIA auth cookies for the created user profile from OAuth2 token. | 199 // Restores GAIA auth cookies for the created user profile from OAuth2 token. |
196 void RestoreAuthSessionImpl(Profile* profile, | 200 void RestoreAuthSessionImpl(Profile* profile, |
197 bool restore_from_auth_cookies); | 201 bool restore_from_auth_cookies); |
198 | 202 |
199 // Initializes RLZ. If |disabled| is true, RLZ pings are disabled. | 203 // Initializes RLZ. If |disabled| is true, RLZ pings are disabled. |
200 void InitRlzImpl(Profile* profile, bool disabled); | 204 void InitRlzImpl(Profile* profile, bool disabled); |
201 | 205 |
202 // Get the NSS cert database for the user represented with |profile| | |
203 // and start certificate loader with it. | |
204 void InitializeCerts(Profile* profile); | |
205 | |
206 // Starts loading CRL set. | 206 // Starts loading CRL set. |
207 void InitializeCRLSetFetcher(const user_manager::User* user); | 207 void InitializeCRLSetFetcher(const user_manager::User* user); |
208 | 208 |
209 // Callback to process RetrieveActiveSessions() request results. | 209 // Callback to process RetrieveActiveSessions() request results. |
210 void OnRestoreActiveSessions( | 210 void OnRestoreActiveSessions( |
211 const SessionManagerClient::ActiveSessionsMap& sessions, | 211 const SessionManagerClient::ActiveSessionsMap& sessions, |
212 bool success); | 212 bool success); |
213 | 213 |
214 // Called by OnRestoreActiveSessions() when there're user sessions in | 214 // Called by OnRestoreActiveSessions() when there're user sessions in |
215 // |pending_user_sessions_| that has to be restored one by one. | 215 // |pending_user_sessions_| that has to be restored one by one. |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
261 // Chrome oauth client id and secret - override values for kiosk mode. | 261 // Chrome oauth client id and secret - override values for kiosk mode. |
262 std::string chrome_client_id_; | 262 std::string chrome_client_id_; |
263 std::string chrome_client_secret_; | 263 std::string chrome_client_secret_; |
264 | 264 |
265 DISALLOW_COPY_AND_ASSIGN(UserSessionManager); | 265 DISALLOW_COPY_AND_ASSIGN(UserSessionManager); |
266 }; | 266 }; |
267 | 267 |
268 } // namespace chromeos | 268 } // namespace chromeos |
269 | 269 |
270 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_SESSION_USER_SESSION_MANAGER_H_ | 270 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_SESSION_USER_SESSION_MANAGER_H_ |
OLD | NEW |