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

Commit 60383b3d authored by Varun Shah's avatar Varun Shah
Browse files

Revert "Adding in verification of calling UID in onShellCommand"

This reverts commit b651d295.

Reason for revert: b/261709193#comment78

Change-Id: I30e993a848a4cab819f2b3d7958f279806e1f530
parent 9ebef39d
Loading
Loading
Loading
Loading
+0 −5
Original line number Diff line number Diff line
@@ -10424,11 +10424,6 @@ public class ActivityManagerService extends IActivityManager.Stub
    public void onShellCommand(FileDescriptor in, FileDescriptor out,
            FileDescriptor err, String[] args, ShellCallback callback,
            ResultReceiver resultReceiver) {
        final int callingUid = Binder.getCallingUid();
        if (callingUid != ROOT_UID && callingUid != Process.SHELL_UID) {
            resultReceiver.send(-1, null);
            throw new SecurityException("Shell commands are only callable by root or shell");
        }
        (new ActivityManagerShellCommand(this, false)).exec(
                this, in, out, err, args, callback, resultReceiver);
    }