Android security tags, read closely by Lightrion

CVE-2024-0046 AI-generated analysis

platform/frameworks/base, PackageManagerService / InstallPackageHelper (install existing package as user)

AI-generated: written from the bulletin and the fixing diffs by claude-fable-5-1, then checked against the code by claude-opus-5-5 (2 corrections). Verify against the commit before relying on it.

Adds a check in the install-existing-package path of InstallPackageHelper so that a request carrying INSTALL_INSTANT_APP is rejected with INSTALL_FAILED_INVALID_URI when the target package is a system app or an updated system app.

Root cause

In services/core/java/com/android/server/pm/InstallPackageHelper.java, the method that installs an already-present package for a user (the one whose cross-user check is labelled "installExistingPackage for user") computed `instantApp` from the INSTALL_INSTANT_APP install flag. After confirming the PackageSetting existed, it went on to install the package for the user without checking whether it was a system or updated-system package. The only instant-app related gate was `snapshot.canViewInstantApps(...)`, which is about whether the caller can see instant apps, not about what kind of package the target is. So a caller that passed the INSTALL_PACKAGES / INSTALL_EXISTING_PACKAGES permission check could have a system app installed for a user as an instant app. The commit title says this should be disallowed.

How the fix works

Completeness

Behavior changes

Per major

Unknowns

Back to March 2024 · Findings