Passing the writing repair mode password flag to verify credential api

Handles the ACTION_PREPARE_REPAIR_MODE_DEVICE_CREDENTIAL intent to
prompt the user for device credentials. Passing the writing repair
mode password flag to the verify credential api when the user is
authenticating.

Bug: 277561275
Test: am start -a android.app.action.PREPARE_REPAIR_MODE_DEVICE_CREDENTIAL
Change-Id: Id018586b0ed535555c157b7516c9571b049978ad
This commit is contained in:
Rhed Jao
2023-05-18 11:16:22 +00:00
parent afc0ea3952
commit f01b99e725
6 changed files with 44 additions and 6 deletions

View File

@@ -496,7 +496,9 @@ public class ConfirmLockPassword extends ConfirmDeviceCredentialBaseActivity {
}
} else if (mForceVerifyPath) {
if (isInternalActivity()) {
startVerifyPassword(credential, intent, 0 /* flags */);
final int flags = mRequestWriteRepairModePassword
? LockPatternUtils.VERIFY_FLAG_WRITE_REPAIR_MODE_PW : 0;
startVerifyPassword(credential, intent, flags);
return;
}
} else {