简体   繁体   English

HostnameVerifier 您的应用程序正在使用 HostnameVerifier 接口的不安全 iImplementation。如何解决此问题?

[英]HostnameVerifier Your app(s) are using an unsafe iImplementation of the HostnameVerifier interface.how to resolve this?

When I am uploading apk version I am getting HostnameVerifier error, Even I am not using Webview in my project I have commented my Webview all over the project当我上传 apk 版本时,我收到 HostnameVerifier 错误,即使我没有在我的项目中使用 Webview 我已经在整个项目中评论了我的 Webview

If you want solve this problem Read this如果你想解决这个问题阅读这个

click here点击这里

  • Action required需要采取的行动

Sign in to your Play Console, and navigate to the Alerts section to see which apps are affected and the deadlines to resolve these issues.登录您的 Play 管理中心,然后导航到“警报”部分,查看哪些应用受到影响以及解决这些问题的截止日期。 Update your affected apps and fix the vulnerability.更新受影响的应用程序并修复漏洞。 Submit the updated versions of your affected apps.提交受影响应用的更新版本。

Upon resubmission, your app will be reviewed again.重新提交后,您的应用将再次被审核。 This process can take several hours.此过程可能需要几个小时。 If the app passes review and is published successfully, then no further action is required.如果应用通过审核并成功发布,则无需进一步操作。 If the app fails review, then the new app version will not be published and you will receive an email notification.如果应用未通过审核,则不会发布新的应用版本,您将收到 email 通知。

  • Additional details额外细节

To properly handle hostname verification, change the implementation of your custom HostnameVerifier interface to perform the following actions:要正确处理主机名验证,请更改自定义 HostnameVerifier 接口的实现以执行以下操作:

If you are using the HostnameVerifier interface, change the implementation of the verify method to return false whenever the hostname of the server does not meet your expectations.如果您正在使用 HostnameVerifier 接口,请更改 verify 方法的实现,以在服务器的主机名不符合您的期望时返回 false。

If you are using the X509HostnameVerifier interface, change the implementation of the verify methods (variants 1, 2, 3) to raise an SSLException whenever the hostname of the server does not meet your expectations.如果您使用 X509HostnameVerifier 接口,请更改验证方法(变体 1、2、3)的实现,以在服务器的主机名不符合您的期望时引发 SSLException。 Ensure that the Exceptions raised within your verify implementation are not caught and suppressed within the method.确保在您的验证实现中引发的异常不会在方法中被捕获和抑制。 Suppressing Exceptions in this manner would cause verify to exit normally, leading the app to trust all hostnames.以这种方式抑制异常会导致验证正常退出,导致应用信任所有主机名。

Also, do not pass AllowAllHostnameVerifier as an argument to setDefaultHostnameVerifier or setHostnameVerifier (eg, via SSLSocketFactory.ALLOW_ALL_HOSTNAME_VERIFIER).此外,不要将 AllowAllHostnameVerifier 作为参数传递给 setDefaultHostnameVerifier 或 setHostnameVerifier(例如,通过 SSLSocketFactory.ALLOW_ALL_HOSTNAME_VERIFIER)。 AllowAllHostnameVerifier turns off hostname verification, thus making your app vulnerable to attack. AllowAllHostnameVerifier 关闭主机名验证,从而使您的应用容易受到攻击。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Google Play 安全警报 - 您的应用正在使用 HostnameVerifier 的不安全实现 - Google Play Security Alert - Your app is using an unsafe implementation of the HostnameVerifier HostnameVerifier 接口的不安全实现 - unsafe implementation of the HostnameVerifier interface HostnameVerifier 接口的不安全实现 - Android - Unsafe implementation of the HostnameVerifier interface - Android 如何修复 HostnameVerifier 的不安全实现 - How to fix unsafe implementation of HostnameVerifier Google Play Alert- 使用主机名验证器的不安全实现的应用程序 - Google Play Alert- App using unsafe implementation of the hostnameVerifier Playstore 漏洞 HostnameVerifier 接口的不安全实现 - Playstore Vulnerablity unsafe implementation of the HostnameVerifier interface 找不到“HostnameVerifier 接口的不安全实现”问题的代码 - Not finding the code for "Unsafe implementation of the HostnameVerifier interface" issue 如何删除 Play 商店错误“HostnameVerifier 的不安全实现” - How to remove a play store error “unsafe implementation of HostnameVerifier” 如何解决“Google Play 将阻止发布任何使用 HostnameVerifier 不安全实现的新应用或更新”? - How to solve "Google Play will block publishing of any new apps or updates that use an unsafe implementation of HostnameVerifier"? 默认主机名验证器 - Default HostnameVerifier
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM