Validate checkInstallConstraints() installer package name
installerPackageName is set when creating PackageInstaller instance. The value is get by context.getPackageName(). But it is possible the application can modify the value by reflection to bypass the security check to access the API. This change will verify it and throws the SecurityException if the name doesn't match. The change here doesn't update the javadoc part, it will be added in the follow up changes. Bug: 280721965 Test: atest InstallConstraintsTest Test: manual. Set fake installerPackageName will throw exception Change-Id: I168e695cf12971f3d770de0f3c9189222bb1707c
Loading
Please register or sign in to comment