- Home /
What's responsible for the `Allow XXX to access your contacts?` when first installing/running a game on Android?
Greetings!
When we install our game to the device, it prompts us with two questions, first one asks to access files, media, photos, etc which is fine, but then the second one asks to access contacts "Allow XXX to access your contacts?" - Which is too scary and could be a turn-off for players.
Plugins we use: AdMob, GooglePlayGames, Chartboost, UnityPurchasing
I need to turn that setting off. I know it's probably a Manifest settings somewhere but what is it exactly?
After I find the responsible setting/parameter, do I have to publish a new version of the game on Google for the changes to take effect?
Any help is appreciated, Thanks.
Answer by Addyarb · Jun 22, 2016 at 03:51 AM
Hi vexe,
GooglePlayGames is likely asking for your [users'] contact permissions. You can always check this by locating your AndroidManifest.xml file within your project. Simply type "Manifest" into your search field in your project tab - and it should pop right up. If there are multiple ones - don't worry. Look through [each of your] Android Manifests and check what plug-in is asking for contact permissions. It will look something like this:
<uses-permission android:name="android.permission.READ_CONTACTS" />
You can safely remove this line if you wish - however keep in mind that it may cause unexpected results if GooglePlayGames (or other plugins) does, in fact, rely on that permission. Try it out!
On a subjective note - don't stress about the permissions too much. The average user simply doesn't care.
Note that for example the Prime31 plugin (as of Aug 16)
Plugins/Android/PlayGameServicesPlugin.aar
asks for GET_ACCOUNTS inside that zip file.
Note that it turns out with Google, you ONLY need GET_ACCOUNTS if you are trying to
get an access token, or
get the user's email address
It seems to be safe to remove the GET_ACCOUNTS permission if you are not trying to do those things.
Thanks for the answer! Yes that permission was the first thing I looked for, there are 4 $$anonymous$$anifest files, couldn't find it in any of them. It seems like it's caused by something else...
Uh oh! Okay well I've done a little digging, and it appears that the
<uses-permission android:name="android.permission.GET_ACCOUNTS" />
permission does the same thing. Is it possible you have overlooked that?
Hmm, I do see a GET_ACCOUNTS! I'll try that next thing in the morning. Thanks!
Woo hoo! I'm happy to hear that. Please let me know how it works out :)
For those reading this in the future - this appears to be caused by something called "Permission Groups."
This means that because the 'READ_CONTACTS' permission is a member of the 'GET_ACCOUNTS' group, 'GET_ACCOUNTS' will request the contacts permission. It's a sort of short-hand way of asking for all permissions associated with accounts I suppose.
For much more information - as well as a helpful table of all of the permissions groups, click here! You have to scroll down quite a bit to get to the table.
I can confirm removing READ_CONTACTS worked! Thanks again!
Thanks so much for this. I was so confused where those extra permissions were co$$anonymous$$g from. After I decompressed the archive, edited the manifest, then compressed it again, that fixed the problem. It's ridiculous it's there in the first place, given the documentation says you need to manually add those permissions if you want to use certain features.
Hi Addyarb, I don't know how to send a message to your profile, so I decided to ask here for your help. I notice that you have the TVNT template and Im having some problems getting to work with it. I asked the developer but They still haven't answer me back. If you have the time and patience, do you think you could help me?. Thank you.
Your answer
Follow this Question
Related Questions
Avoid android permission prompt when returning to app after changing settings on device? 0 Answers
does unity 5.3 android sms billing status require configuration changes ? 0 Answers
Disable permission requests 0 Answers
What triggers the Internet Access permission, when it's set to auto on Android? 1 Answer
Disable permission dialog in Unity 5 2 Answers