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

Commit 070fe639 authored by Andres Morales's avatar Andres Morales
Browse files

[LockSettings] clear secure user id when user is removed

Needed for QCOM HALs and for general good housekeeping

Bug: 22011857
Change-Id: I6cc157a88ee125ecbf81fc51c226c63ba1d34b80
parent 616f035b
Loading
Loading
Loading
Loading
+9 −0
Original line number Diff line number Diff line
@@ -701,6 +701,15 @@ public class LockSettingsService extends ILockSettings.Stub {

        final KeyStore ks = KeyStore.getInstance();
        ks.onUserRemoved(userId);

        try {
            final IGateKeeperService gk = getGateKeeperService();
            if (gk != null) {
                    gk.clearSecureUserId(userId);
            }
        } catch (RemoteException ex) {
            Slog.w(TAG, "unable to clear GK secure user id");
        }
    }

    private static final String[] VALID_SETTINGS = new String[] {