Android权限GET_ACCOUNTS和USE_CREDENTIALS自动显示权限、Android、USE_CREDENTIALS、GET_ACCOUNTS

2023-09-07 16:53:25 作者:莪不懂得愛

它已经,因为我有时间我的应用程序工作好几个月。今天我下载了最新的Andr​​oid Studio和SDK,我发现一个问题,我建立了应用程序之后。

It has been quite a few months since I had time to work on my app. And today I downloaded latest Android Studio and SDK, I found a problem after I built the app.

我的Andr​​oidManifest文件不需要在GET_ACCOUNTS或USE_CREDENTIALS任何权限,但是它们将显示为新增加的权限,当我试图上传谷歌应用Play商店。我没有使用谷歌在游戏中玩游戏服务,但​​它不是这个样子的我做了此更新。

My AndroidManifest file does NOT require any permissions on GET_ACCOUNTS or USE_CREDENTIALS, however they are shown as new added permissions when I tried to upload the app in Google Play store. I did use Google Play Games service in the game, but it was not like this before I did this update.

是否有人知道为什么吗?我Google了一段时间,但找不到任何线索。

Does anybody know why? I Googled a while but could not find any clue..

推荐答案

如果您最近更新,请检查您是否切换到谷歌Play服务7.5在你的的build.gradle 文件,如

If you recently updated, check to see if you switched to Google Play services 7.5 with a line in your build.gradle file such as

compile 'com.google.android.gms:play-services:7.5.0'

谷歌Play服务的7.5自动将所需的权限 - 当您使用 com.google.android.gms:发挥服务 - 说你正在使用的每个的谷歌Play的一部分服务,可能需要添加更多的权限比您预期。

Google Play services 7.5 automatically adds required permissions - when you use com.google.android.gms:play-services - that says you are using every part of Google Play services, potentially adding more permissions than you intended.

相反,你应该选择包括通过使用不同的相关性,如使用哪些API :

compile 'com.google.android.gms:play-services-games:7.5.0'
compile 'com.google.android.gms:play-services-drive:7.5.0'

(假设你需要云端保存的游戏支持)