Worklight 6.0.0,针对 iPad。
我有一个简单的演示应用程序,目前没有认证。我正在演示反向代理的使用。所以我正在使用 Build for Remote Server workaround 构建我的应用程序并且可以在 xcode 中看到正确的服务器规范。我有一些适配器调用,但对于特定的演示场景,我还想显式调用
WL.Client.connect( ... );
如果我使用 http 连接,我会看到这样的请求:
http://192.168.0.19/MyApp/apps/services/api/Work01/ipad/init
而且效果很好。相反,如果我使用 SSL 连接,正如预期的那样,我会看到这个
https://192.168.0.19:443/Infrabel01/apps/services/api/Work01/ipad/init
我收到以下错误。
> [ERROR ] FWLSE0059E: Login into realm 'NullLoginModule' failed. The
> environment 'ipad' supports multiple versions, therefore you must
> request it with a version parameter.. [project Infrabel01] The
> environment 'ipad' supports multiple versions, therefore you must
> request it with a version parameter. [ERROR ]
> FWLSE0117E: Error code: 4, error description: AUTHENTICATION_ERROR,
> error message: An Error occurred while performing authentication using loginModule
> NullLoginModule, User Identity Not available. [project Infrabel01]
> [project Infrabel01]
“使用版本参数请求它”很有趣。我需要传递一些额外的参数吗?还是通过 SSL 连接需要身份验证的总体含义?
最佳答案
我遇到了同样的问题。
我已经通过在 WL 应用程序中使用服务器的真实 IP 地址而不是使用本地主机解决了这个问题:
- 当模拟器正在运行您的应用时,按“菜单”按钮。
- 选择更改您的服务器 URL
- 删除“localhost”并使用 IP 地址。
- 接受并重试。
这解决了我的问题。
关于ssl - 使用 SSL 的 Worklight 6.0 应用程序,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18589894/