- QUERY_ALL_PACKAGES(Broad package visibility) permission allows the app built with targetSdkVersion 30+ to check the installed app inventory of the device with Android 11+. The app using this permission can query all installed app lists from the smartphone
<uses-permission android:name="android.permission.QUERY_ALL_PACKAGES"
tools:ignore="QueryAllPackagesPermission"/>
- Although permission needed for above request in android device but using
QUERY_ALL_PACKAGES create issues sometimes while publish app on play store
as this is highly sensitive permission
- so below query block can achieve our goal with out permission.
- add this code in
androidmanifest.xml file with other permission to omit QUERY_ALL_PACKAGE permission
<queries>
<intent>
<action android:name="android.intent.action.GET_CONTENT" />
<data android:mimeType="*/*" />
</intent>
<intent>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.BROWSABLE" />
<data android:scheme="https" />
</intent>
<intent>
<action android:name="android.support.customtabs.action.CustomTabsService" />
</intent>
<intent>
<action android:name="android.intent.action.VIEW" />
<data
android:mimeType="*/*"
android:scheme="*" />
</intent>
<intent>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.BROWSABLE" />
<data
android:host="pay"
android:mimeType="*/*"
android:scheme="upi" />
</intent>
<intent>
<action android:name="android.intent.action.MAIN" />
</intent>
<intent>
<action android:name="android.intent.action.SEND" />
<data android:mimeType="*/*" />
</intent>
<intent>
<action android:name="rzp.device_token.share" />
</intent>
</queries>