[FIXED] Violation Request Install Packages Permission: Permission use is not directly related to your app's core purpose
Issue
Violation Request Install Packages Permission: Permission use is not directly related to your app’s core purpose.
We found that your app is not compliant with how REQUEST_INSTALL_PACKAGES
permission is allowed to be used. Specifically, the use of the permission is not directly related to the core purpose of the app.
Previous answers recommended in
Ionic capacitor remove REQUEST_INSTALL_PACKAGES permission for android build
<uses-permission android:name="android.permission.REQUEST_INSTALL_PACKAGES" tools:node="remove"/>
In the AndroidManifest.xml
Or removing from Android Manifest.xml Merged Manifest Tab, which has no reference to
android.permission.REQUEST_INSTALL_PACKAGES
.
The only Cordova plugin I use is localforage-cordovasqlitedriver
list of capacitor plugins,
How do I effectively search through the plugins and project to find which one is adding android.permission.REQUEST_INSTALL_PACKAGES
.
I also found
public static final String REQUEST_INSTALL_PACKAGES = "android.permission.REQUEST_INSTALL_PACKAGES";
in ~/Library/Android/sdk/platforms/android-32/android.jar!/android/Manifest.class
Solution
Here is what I found,
<uses-permission android:name="android.permission.REQUEST_INSTALL_PACKAGES" tools:node="remove"/>
adds the permission into the manifest-merger-release-report.txt
So yes it is removed from the App, but the report says the REQUEST_INSTALL_PACKAGES permission is in the App and that is enough to get rejected by Google Play store. Also any releases in Open testing, Closed testing, or Internal testing will that have this in the manifest-merger-release-report.txt will cause the release to get rejected.
see
https://github.com/Baseflow/flutter-permission-handler/issues/869
Answered By – Thomas Degroot
Answer Checked By – Dawn Plyler (FixeMe Volunteer)