android – 为什么我收到警告 – 此应用程序不符合Google Play权限政策,即使我的最新版本不需要这些权限?
内容导读
互联网集市收集整理的这篇技术教程文章主要介绍了android – 为什么我收到警告 – 此应用程序不符合Google Play权限政策,即使我的最新版本不需要这些权限?,小编现在分享给大家,供广大互联网技能从业者学习和参考。文章包含3062字,纯文字阅读大概需要5分钟。
内容图文
它显示了这条消息
This app does not meet the Google Play permissions policy relating to the use of SMS or CALL_LOG. You must fix this before March 9. 2019 or your app will be removed from Google Play. Note: if you have recently made a change, it can take up to 12 hours to update this message.
我之前版本的应用程序拥有此权限,并在被拒绝时申请例外我在2周前更新了应用程序并删除了此权限.但现在我得到了这个消息.
解决方法:
我在上一个应用版本上也收到了这个警告.
说明:您收到此警告是因为您以某种方式直接或间接使用了一些不符合Google Play权限策略的权限.
间接意味着,您在项目中使用的任何第三方库可能已经在使用这些权限.当您构建项目时,它将所有Manifest文件合并到一个Merged Manifest文件中.这就是您收到此警告的原因,因为您的最终清单具有任何这些权限.
解决方案1:构建项目后,
>打开项目的AndroidManifest文件.
>打开底部的Merged Manifest选项卡.
>搜索任何这些权限. (示例 – READ_SMS)
>如果你有任何,现在是时候删除它们了.检查示例
示例:如果您在Merged Manifest文件中看到READ_SMS权限,那么现在打开项目的AndroidManifest文件并添加下面写的行以从项目中删除该权限 –
<uses-permission android:name="android.permission.READ_SMS" tools:node="remove" />
在AndroidManifest文件中添加上述权限行,就是这样.它将从Merged Manifest文件中删除Permission,您的问题将得到解决.
AndroidManifest文件
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="com.example.myapp">
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.READ_SMS" tools:node="remove" />
<application
android:name=".MyApp"
android:allowBackup="false"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:supportsRtl="true"
android:theme="@style/AppTheme"
tools:ignore="GoogleAppIndexingWarning"
tools:replace="android:allowBackup">
<activity
android:name=".SplashActivity"
android:screenOrientation="portrait"
android:theme="@style/FullscreenTheme">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
解决方案2:替换/删除使用这些权限的第三方库.
更新:
解决方案3:为安全起见,您可以在AndroidManifest文件中添加这些行.
<uses-permission
android:name="android.permission.RECEIVE_SMS"
tools:node="remove" />
<uses-permission
android:name="android.permission.READ_SMS"
tools:node="remove" />
<uses-permission
android:name="android.permission.SEND_SMS"
tools:node="remove" />
<uses-permission
android:name="android.permission.WRITE_SMS"
tools:node="remove" />
<uses-permission
android:name="android.permission.RECEIVE_WAP_PUSH"
tools:node="remove" />
<uses-permission
android:name="android.permission.RECEIVE_MMS"
tools:node="remove" />
<uses-permission
android:name="android.permission.READ_CALL_LOG"
tools:node="remove" />
<uses-permission
android:name="android.permission.WRITE_CALL_LOG"
tools:node="remove" />
<uses-permission
android:name="android.permission.PROCESS_OUTGOING_CALLS"
tools:node="remove" />
如果使用的话,这些行将根据Permission Policy删除所有受限制的许可.
希望它会有所帮助.
内容总结
以上是互联网集市为您收集整理的android – 为什么我收到警告 – 此应用程序不符合Google Play权限政策,即使我的最新版本不需要这些权限?全部内容,希望文章能够帮你解决android – 为什么我收到警告 – 此应用程序不符合Google Play权限政策,即使我的最新版本不需要这些权限?所遇到的程序开发问题。 如果觉得互联网集市技术教程内容还不错,欢迎将互联网集市网站推荐给程序员好友。
内容备注
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 gblab@vip.qq.com 举报,一经查实,本站将立刻删除。
内容手机端
扫描二维码推送至手机访问。