| 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 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_EXISTING_USER_CONTROLLER_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_EXISTING_USER_CONTROLLER_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_EXISTING_USER_CONTROLLER_H_ | 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_EXISTING_USER_CONTROLLER_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 | 9 |
| 10 #include <memory> | 10 #include <memory> |
| (...skipping 20 matching lines...) Expand all Loading... |
| 31 #include "components/user_manager/user.h" | 31 #include "components/user_manager/user.h" |
| 32 #include "content/public/browser/notification_observer.h" | 32 #include "content/public/browser/notification_observer.h" |
| 33 #include "content/public/browser/notification_registrar.h" | 33 #include "content/public/browser/notification_registrar.h" |
| 34 #include "ui/gfx/geometry/rect.h" | 34 #include "ui/gfx/geometry/rect.h" |
| 35 #include "url/gurl.h" | 35 #include "url/gurl.h" |
| 36 | 36 |
| 37 namespace base { | 37 namespace base { |
| 38 class ListValue; | 38 class ListValue; |
| 39 } | 39 } |
| 40 | 40 |
| 41 namespace authpolicy { |
| 42 |
| 43 class ActiveDirectoryAccountData; |
| 44 |
| 45 } // namespace authpolicy |
| 46 |
| 41 namespace chromeos { | 47 namespace chromeos { |
| 42 | 48 |
| 49 class AuthPolicyLoginHelper; |
| 43 class BootstrapUserContextInitializer; | 50 class BootstrapUserContextInitializer; |
| 44 class CrosSettings; | 51 class CrosSettings; |
| 45 class LoginDisplayHost; | 52 class LoginDisplayHost; |
| 46 class OAuth2TokenInitializer; | 53 class OAuth2TokenInitializer; |
| 47 | 54 |
| 48 namespace login { | 55 namespace login { |
| 49 class NetworkStateHelper; | 56 class NetworkStateHelper; |
| 50 } | 57 } |
| 51 | 58 |
| 52 // ExistingUserController is used to handle login when someone has | 59 // ExistingUserController is used to handle login when someone has |
| (...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 272 | 279 |
| 273 // Callback invoked when |token_handle_util_| finishes token check. | 280 // Callback invoked when |token_handle_util_| finishes token check. |
| 274 void OnTokenHandleChecked( | 281 void OnTokenHandleChecked( |
| 275 const AccountId&, | 282 const AccountId&, |
| 276 TokenHandleUtil::TokenHandleStatus token_handle_status); | 283 TokenHandleUtil::TokenHandleStatus token_handle_status); |
| 277 | 284 |
| 278 // Clear the recorded displayed email, displayed name, given name so it won't | 285 // Clear the recorded displayed email, displayed name, given name so it won't |
| 279 // affect any future attempts. | 286 // affect any future attempts. |
| 280 void ClearRecordedNames(); | 287 void ClearRecordedNames(); |
| 281 | 288 |
| 289 // Callback invoked after authentication against Active Directory server. |
| 290 void OnActiveDirectoryAuth( |
| 291 authpolicy::ErrorType error, |
| 292 const authpolicy::ActiveDirectoryAccountData& account_data); |
| 293 |
| 282 // Public session auto-login timer. | 294 // Public session auto-login timer. |
| 283 std::unique_ptr<base::OneShotTimer> auto_login_timer_; | 295 std::unique_ptr<base::OneShotTimer> auto_login_timer_; |
| 284 | 296 |
| 285 // Auto-login timeout, in milliseconds. | 297 // Auto-login timeout, in milliseconds. |
| 286 int auto_login_delay_; | 298 int auto_login_delay_; |
| 287 | 299 |
| 288 // AccountId for public session auto-login. | 300 // AccountId for public session auto-login. |
| 289 AccountId public_session_auto_login_account_id_ = EmptyAccountId(); | 301 AccountId public_session_auto_login_account_id_ = EmptyAccountId(); |
| 290 | 302 |
| 291 // AccountId for ARC kiosk auto-login. | 303 // AccountId for ARC kiosk auto-login. |
| 292 AccountId arc_kiosk_auto_login_account_id_ = EmptyAccountId(); | 304 AccountId arc_kiosk_auto_login_account_id_ = EmptyAccountId(); |
| 293 | 305 |
| 294 // Used to execute login operations. | 306 // Used to execute login operations. |
| 295 std::unique_ptr<LoginPerformer> login_performer_; | 307 std::unique_ptr<LoginPerformer> login_performer_; |
| 296 | 308 |
| 309 // Used to execute login to AuthPolicy service. It provides authentication |
| 310 // against Active Directory server. |
| 311 std::unique_ptr<AuthPolicyLoginHelper> authpolicy_login_helper_; |
| 312 |
| 297 // Delegate to forward all authentication status events to. | 313 // Delegate to forward all authentication status events to. |
| 298 // Tests can use this to receive authentication status events. | 314 // Tests can use this to receive authentication status events. |
| 299 AuthStatusConsumer* auth_status_consumer_ = nullptr; | 315 AuthStatusConsumer* auth_status_consumer_ = nullptr; |
| 300 | 316 |
| 301 // AccountId of the last login attempt. | 317 // AccountId of the last login attempt. |
| 302 AccountId last_login_attempt_account_id_ = EmptyAccountId(); | 318 AccountId last_login_attempt_account_id_ = EmptyAccountId(); |
| 303 | 319 |
| 304 // Whether the last login attempt was an auto login. | 320 // Whether the last login attempt was an auto login. |
| 305 bool last_login_attempt_was_auto_login_ = false; | 321 bool last_login_attempt_was_auto_login_ = false; |
| 306 | 322 |
| (...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 387 | 403 |
| 388 // Factory of callbacks. | 404 // Factory of callbacks. |
| 389 base::WeakPtrFactory<ExistingUserController> weak_factory_; | 405 base::WeakPtrFactory<ExistingUserController> weak_factory_; |
| 390 | 406 |
| 391 DISALLOW_COPY_AND_ASSIGN(ExistingUserController); | 407 DISALLOW_COPY_AND_ASSIGN(ExistingUserController); |
| 392 }; | 408 }; |
| 393 | 409 |
| 394 } // namespace chromeos | 410 } // namespace chromeos |
| 395 | 411 |
| 396 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_EXISTING_USER_CONTROLLER_H_ | 412 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_EXISTING_USER_CONTROLLER_H_ |
| OLD | NEW |