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

Commit adf85dac authored by Bookatz's avatar Bookatz
Browse files

UserController.switchUser accepts MANAGE_USERS

switchUser used to be permitted provided the caller has MANAGE_USERS
or CREATE_USERS. Recently it was changed to require
INTERACT_ACROSS_USERS_FULL, but that was inappropriate.

Fixes: 138952201
Test: manually verified bug is fixed
Change-Id: I49116859a9a693e657c5002235746ab4cf2cbef2
parent ce81d325
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -1342,7 +1342,6 @@ class UserController implements Handler.Callback {
    }

    boolean switchUser(final int targetUserId) {
        checkCallingPermission(INTERACT_ACROSS_USERS_FULL, "switchUser");
        enforceShellRestriction(UserManager.DISALLOW_DEBUGGING_FEATURES, targetUserId);
        int currentUserId = getCurrentUserId();
        UserInfo targetUserInfo = getUserInfo(targetUserId);