This is my section of permissions of my manifest:
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.adelco.ventamovil"
android:versionCode="1"
android:versionName="1.0">
<uses-sdk android:minSdkVersion="8" />
<uses-permission android:name="android.permission.INTERNET"></uses-permission>
<uses-permission android:name="android.permission.INSTALL_PACKAGES"></uses-permission>
<uses-permission android:name="android.permission.DELETE_PACKAGES"></uses-permission>
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"></uses-permission>
But when I try to install the package, the wizzard only shows the Internet and Write External Storage permissions.
The DDMS perspective throws this warning message when I install the application:
03-28 10:48:36.627: WARN/PackageManager(144): Not
granting permission android.permission.INSTALL_PACKAGES to package
com.adelco.ventamovil (protectionLevel=3 flags=0xbe44)
03-28 10:48:36.627: WARN/PackageManager(144): Not granting permission
android.permission.DELETE_PACKAGES to package com.adelco.ventamovil
(protectionLevel=3 flags=0xbe44)
What is happening here....?
Thanks!!
Sorry,
Install, delete packages are system permissions. You won't be able to obtain them unless your app is signed with the device's platform certificate (which is impossible unless you have access to the manufacturer's signing cert).
As you can imagine, that'd be a serious security problem if an arbitrary application could silently install other applications.
The best you can do is send the user to the package install page and let them take action if they wish. Take a look at this action intent you can send to start this process for install,
http://developer.android.com/reference/android/content/Intent.html#ACTION_INSTALL_PACKAGE
and for uninstall,
http://developer.android.com/reference/android/content/Intent.html#ACTION_UNINSTALL_PACKAGE
INSTALL_PACKAGES and DELETE_PACKAGES are either in the group signature or signatureOrSystem and thus can't be granted to an "ordinary" app:
A permission that the system grants only to applications that are in the Android system image or that are signed with the same certificates as those in the system image
See android:protectionLevel.
Did you put your permissions like that?
<manifest
xmlns:android="http://schemas.android.com/apk/res/android"
package="com.your.package"
android:versionCode="1"
android:versionName="1.0" >
<uses-sdk android:minSdkVersion="8" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.INSTALL_PACKAGES" />
<uses-permission android:name="android.permission.DELETE_PACKAGES" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
Related
I have an app built using Xamarin for android.
I keep getting the same email saying my app is using Manage_External_Storage and keeps getting rejected even though it's not in the manifest. The app at some time had requested that permission but we have removed that from the manifest. Even the Play console App bundle explorer reads the correct permissions. Below are the permissions from for that app bundle from the app bundle explorer in Play Console
android.permission.ACCESS_NETWORK_STATE,
android.permission.CAMERA,
android.permission.INTERNET,
android.permission.USE_BIOMETRIC,
android.permission.USE_FINGERPRINT,
android.permission.WAKE_LOCK
I have also checked the manifest of the compiled .aab in android studio and it does not have that permission in there.
<?xml version="1.0" encoding="UTF-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" android:versionCode="26" android:versionName="1.0.26" android:installLocation="0" android:compileSdkVersion="30" android:compileSdkVersionCodename="11" package="com.test.app" platformBuildVersionCode="30" platformBuildVersionName="11">
<uses-sdk android:minSdkVersion="26" android:targetSdkVersion="30" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-feature android:name="android.hardware.camera" android:required="false" />
<uses-feature android:name="android.hardware.camera.autofocus" android:required="false" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.CAMERA" />
<uses-permission android:name="android.permission.USE_FINGERPRINT" />
<uses-permission android:name="android.permission.WAKE_LOCK" />
<uses-permission android:name="android.permission.USE_BIOMETRIC" />
</manifest>
Does anyone have any idea why this is happening?
If you remove the Permission, you need to update the build number on Internal Track. you have to update the build on every track(Open testing, Closed testing, Production, etc.) even if permission are disabled in android 11.
Here are some threads you can refer to:
Google Play store continuous rejection due to NOT compliant with the All Files Access Permissions policy
Google Play App Rejection - Not a core feature - Use of All files access
I have an Android app written by Xamarin, and it works perfectly fine when debugging.
But when I want to release it, my *.apk installer does not ask for INTERNET permission, therefore my app crashes whenever it requires connection, which is almost in every activity since it's an online app.
I have added the permission in my manifest file, but for some reason, the app only asks for Reading and Writing data from SD card permission and totally ignores internet permission.
Here is my manifest file:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="ComicCity.ComicCity" android:versionCode="1" android:versionName="1.0" android:installLocation="preferExternal">
<uses-sdk android:minSdkVersion="19" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.DELETE_CACHE_FILES" />
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<application android:label="ComicCity" android:icon="#drawable/CCicon"></application>
</manifest>
Internet is in the normal permissions list and thus you will not get prompted as it is auto-granted
If an app declares in its manifest that it needs a normal permission, the system automatically grants the app that permission at install time. The system does not prompt the user to grant normal permissions, and users cannot revoke these permissions.
Re: https://developer.android.com/guide/topics/permissions/normal-permissions.html
I made an android app and published it on play store. I mentioned all the app specific required permissions in manifest.xml file, But when I am installing it from playstore it not asking the permissions like it asked for other apps.
I found one similar question here But did'nt get what I am looking for
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.agrawalgaurav.www.nighttorch">
<uses-permission android:name="android.permission.INTERNET" />
<uses-sdk
android:minSdkVersion="8"
android:targetSdkVersion="15" />
<uses-permission android:name="android.permission.CAMERA" />
<uses-feature android:name="android.hardware.camera" />
You might have installed the app in a phone running Android version 6.0 or above where the user should be requested permission on runtime and not at install time
Refer this https://developer.android.com/training/permissions/requesting.html
If you have Android 6 or higher permissions will be asking in runtime. Some permissions probably will not be asking in runtime, for example Internet permission, because they are from Normal Permissions group.
It seems like Read/Write external storage and Read phone state permissions are automatically added to the manifest on building the android apk. Are these necessary for all React Native android apps? Is there any way to remove these permissions?
Looking at the build/output/logs/manifest-merger-debug-report.txt I see:
android:uses-permission#android.permission.READ_EXTERNAL_STORAGE
IMPLIED from `/***/android/app/src/main/AndroidManifest.xml:1:1-22:12 reason: org.webkit.android_jsc` requested WRITE_EXTERNAL_STORAGE
It feels weird that I'll see these permissions being requested if I install the app from the Play store if I'm not using them.
I have an answer.
AndroidManifest.xml
Add this to manifest which should be line 1
xmlns:tools="http://schemas.android.com/tools"
It should look like this
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="YOUR PACKAGE NAME">
Now you can remove the permissions with this
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" tools:node="remove" />
So my permissions for a simple app are
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" tools:node="remove" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" tools:node="remove" />
Don't remove SYSTEM.ALERT.WINDOW, you will have problems in development.
Testing my Android app (made in Unity) on the live store shows that it requests "Device ID & call information". As far as I can tell, I don't request these permissions. Here are the permissions I request in my AndroidManifest.xml file. Is this a permission required for all apps? Or is it hidden under one of these other permissions?
<uses-permission android:name="com.android.vending.BILLING" />
<uses-sdk android:minSdkVersion="9" android:targetSdkVersion="19" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
Thanks!
I just spent an absurd amount of time trying to resolve this so figured I would share with anyone out there going through a similar agony.
Removing the permissions from your manifest will not necessarily remove them from the final build. Unity auto-detects required permissions from all included libraries. The libraries which are most likely causing you to have this permission included are from the Facebook sdk.
If you want to keep the Facebook sdk in the build, there's a relatively straightforward solution. Remove the Facebook SDK (completely) and install a version <= 7.80. For whatever reason, the changes to the sdk in 7.9+ prompt Unity to auto-include the READ_PHONE_STATE permission which triggers the Device ID & Call Information permission warning in google play.