Skip to content
Commit c701e7e6 authored by Philip P. Moltmann's avatar Philip P. Moltmann
Browse files

Grant permissions to updated system packages

isSystemPackage calls isSysComponentOrPersistentPlatformSignedPrivApp
which checks the uid of the app.

If we call getSystemPackageInfo on an updated system package we get
the info for the original apk installed on the system permission, not
the updated apk.

This original is not a currently registered package, hence it does not
have an uid and reports -1.

Hence if you pass the result of getSystemPackageInfo into
isSysComponentOrPersistentPlatformSignedPrivApp the first check always
triggers which then makes isSystemPackage assume the package is not a
system package.

Fixes: 115854330
Test: Executed steps in the bug (updated gmscore, restarted, tried to
add second user which triggers default grant policy for the second user)

Change-Id: I74745f8985082490a1f770d7682a964518782dd1
parent b0be05c5
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment