UseCleartextTraffic不允许 [英] usesCleartextTraffic not permitted

查看:184
本文介绍了UseCleartextTraffic不允许的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我过去一年都将构建发送到codenameone,但是突然之间,所有新的android构建应用都无法使用http协议,从而导致 java.io.IOException:明文HTTP流量禁止进入domainname.com。

I use to send build to codenameone for year, but suddenly all the newly android build apps is not working with http protocol, getting "java.io.IOException: Cleartext HTTP traffic to domainname.com not permitted."

我通过Google搜索,但没有找到有关codenameone的任何有关android的解决方案。

I search through google but not finding any solutions about android for codenameone.

我了解苹果公司已将此强制为https,但不是android。

I understand apple had force this to https, but not android.

有人可以在这里提供帮助吗?

Can somebody help here?

尝试在此项目的codenameone设置页面上播放以添加构建提示

Try to play around the codenameone setting page for this project to add a build hint

android.xapplication=<application android:usesCleartextTraffic="true" />

但效果不佳。

推荐答案

我们已按照Google的要求在周末迁移到API级别28。在某些方面,这打破了它们通常所具有的兼容性……这就是这样的方面。

We migrated to API level 28 over the weekend as required by Google. This broke compatibility on some fronts as is typical to them... That's one such front.

您要查找的是 android.xapplication_attr ,但该参数也不正确:

What you're looking for is android.xapplication_attr but the argument isn't correct either:

android.xapplication_attr=android:usesCleartextTraffic="true"

这篇关于UseCleartextTraffic不允许的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆