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

Commit 4934f58c authored by Pinyao Ting's avatar Pinyao Ting Committed by Automerger Merge Worker
Browse files

Merge "Validate userId when publishing shortcuts" into rvc-dev am: 72aee140 am: fedf1c8c

parents b4e7f02f fedf1c8c
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -1733,6 +1733,10 @@ public class ShortcutService extends IShortcutService.Stub {
            android.util.EventLog.writeEvent(0x534e4554, "109824443", -1, "");
            throw new SecurityException("Shortcut package name mismatch");
        }
        final int callingUid = injectBinderCallingUid();
        if (UserHandle.getUserId(callingUid) != si.getUserId()) {
            throw new SecurityException("User-ID in shortcut doesn't match the caller");
        }
    }

    private void verifyShortcutInfoPackages(