Skip to content

Commit

Permalink
Merge branch 'omp-jb53701' into 'master'
Browse files Browse the repository at this point in the history
[nemo-qml-plugin-devicelock] Handle SecurityCodeExpired while Unlocking. Contributes to JB#53701

See merge request mer-core/nemo-qml-plugin-devicelock!58
  • Loading branch information
pvuorela committed May 27, 2021
2 parents 3569d10 + 7d63985 commit f10be30
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/nemo-devicelock/host/hostdevicelock.cpp
Expand Up @@ -160,6 +160,12 @@ void HostDeviceLock::enterSecurityCode(const QString &code)
case LockedOut:
lockedOut();
break;
case Evaluating:
// Set currentCode to use it as oldCode in case evaluation
// reveals it is expired and must be changed with a newCode
m_currentCode = code;
unlockFinished(result, Authenticator::SecurityCode);
break;
default:
unlockFinished(result, Authenticator::SecurityCode);
break;
Expand Down Expand Up @@ -241,6 +247,9 @@ void HostDeviceLock::unlockFinished(int result, Authenticator::Method method)
}
break;
case SecurityCodeExpired:
enterCodeChangeState(&HostAuthenticationInput::feedback);
authenticationResumed(AuthenticationInput::SecurityCodeExpired, QVariantMap(), Authenticator::SecurityCode);
break;
case SecurityCodeInHistory:
case LockedOut:
if (m_state == Canceled) {
Expand Down

0 comments on commit f10be30

Please sign in to comment.