Commit e7e2864c authored by Ryan Hansberry's avatar Ryan Hansberry Committed by Commit Bot

[Smart Lock] Do not proceed with authentication if AuthAttempt cannot start.

Bug: 943211
Change-Id: I181ad7956e30e9919b7084fce274a62d0158e5af
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1755188Reviewed-by: default avatarKyle Horimoto <khorimoto@chromium.org>
Commit-Queue: Ryan Hansberry <hansberry@chromium.org>
Cr-Commit-Position: refs/heads/master@{#687363}
parent 6e721199
......@@ -351,6 +351,8 @@ void EasyUnlockService::AttemptAuth(const AccountId& account_id) {
const EasyUnlockAuthAttempt::Type auth_attempt_type =
GetType() == TYPE_REGULAR ? EasyUnlockAuthAttempt::TYPE_UNLOCK
: EasyUnlockAuthAttempt::TYPE_SIGNIN;
PA_LOG(VERBOSE) << "User began auth attempt (unlock or sign in attempt).";
if (auth_attempt_) {
PA_LOG(VERBOSE) << "Already attempting auth, skipping this request.";
return;
......@@ -383,6 +385,7 @@ void EasyUnlockService::AttemptAuth(const AccountId& account_id) {
SmartLockMetricsRecorder::SmartLockAuthResultFailureReason::
kAuthAttemptCannotStart);
auth_attempt_.reset();
return;
}
// TODO(tengs): We notify ProximityAuthSystem whenever unlock attempts are
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment