也许你面容憔悴
也许你面容憔悴
  • 发布:2016-05-24 16:11
  • 更新:2016-11-02 18:03
  • 阅读:6711

【报Bug】提交到Google Play被拒,原因是:您的应用中 X509TrustManager 接口(与 Apache HTTP 客户端配合使用)的实施方式不安全,因此会造成安全漏洞。

分类:5+ SDK

详细问题描述
这是Google发给我的邮件被拒原因的内容:

Below is the list of vulnerabilities and the corresponding APK versions that were detected in your recent submission. Please upgrade your app(s) as soon as possible and increment the version number of the upgraded APK.

TrustManager
To properly handle SSL certificate validation, change your code in the checkServerTrusted method of your custom X509TrustManager interface to raise either CertificateException or IllegalArgumentException whenever the certificate presented by the server does not meet your expectations. To confirm you’ve updated correctly, submit the updated version to the Developer Console and check back after five hours. If the app hasn’t been correctly upgraded, we will display a warning.

For additional information and next steps, please see this Google Help Center article.

相关链接:
https://support.google.com/faqs/answer/6346016

重现步骤
[步骤]
[结果]
[期望]

运行环境
[系统版本]
[浏览器版本]
[IDE版本]
Eclipse Java EE IDE for Web Developers.
Version: Kepler Service Release 2
Build id: 20140224-0627

[mui版本]
3.0.0

附件
[代码片段]
[安装包]

备注
应用正准备上线啊。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。。

2016-05-24 16:11 负责人:无 分享
已邀请:
Android_磊子

Android_磊子

此问题主要是解决,开发者开发应用存在https请求但证书非正规的情况,此时默认接受所有证书。
可在manifest.json中进行配置"plus": {"ssl":{"untrustedca":"refuse"}} 拒绝所有https请求。

  • 也许你面容憔悴 (作者)

    我是用本地打包的添加了配置但是没用。

    2016-05-26 16:11

  • 也许你面容憔悴 (作者)

    本地打包时这个问题有解吗?自己写的API接口是没有用到HTTPS的,应该是哪个SDK用到了。APP再不上传到Google Play项目就要逾期了。

    2016-05-27 11:10

  • Android_磊子

    目前没有快的解决办法。(国内的一些市场这样是可以上传的)

    市场只是,检测是否含有隐患代码,不会具体到执行不执行。5+要服务不同开发者的需求,sdk中是存在这些代码的,将来可能在这地方进行整理。现在一时没有解决方案。

    2016-05-27 11:49

周羊羊

周羊羊

邮件里应该写了,有问题的是百度地图里的两个类,
不需要获取位置信息的话,直接把百度地图的 jar 包都删掉就行。

如果是其他第三方 SDK 有问题,查一下是哪家的,升级版本或者去问他们的技术客服这个问题有没有修复,我的 app 里用了 ShareSDK,友盟和个推,开始不知道是百度地图的问题,这三家都说他们的最新版这个问题已经修复了(之前的版本确实是有问题)

该问题目前已经被锁定, 无法添加新回复