Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e30d4a31 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Clear Gatekeeper state before a new enrollment"

parents 216461d8 54c19b62
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -583,6 +583,9 @@ public class SyntheticPasswordManager {
            sid = GateKeeper.INVALID_SECURE_USER_ID;
            applicationId = transformUnderWeaverSecret(pwdToken, weaverSecret);
        } else {
            // In case GK enrollment leaves persistent state around (in RPMB), this will nuke them
            // to prevent them from accumulating and causing problems.
            gatekeeper.clearSecureUserId(fakeUid(userId));
            // GateKeeper based user password
            GateKeeperResponse response = gatekeeper.enroll(fakeUid(userId), null, null,
                    passwordTokenToGkInput(pwdToken));