使用SSL的Worklight 6.0应用程序 [英] Worklight 6.0 application using SSL

查看:88
本文介绍了使用SSL的Worklight 6.0应用程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

针对iPad的Worklight 6.0.0.

Worklight 6.0.0, targeting iPad.

我有一个简单的演示应用程序,目前没有身份验证.我正在演示反向代理的使用.因此,我正在使用构建远程服务器的解决方法来构建应用程序并可以在xcode中看到正确的服务器规格.我有一些适配器调用,但是对于特定的演示场景,我还想显式调用

I have a simple demonstration application, no authentication at present. I am demonstrating use of reverse proxy. So I am building my application using the Build for Remote Server workaround and can see in xcode the correct server specification. I have some adapter calls, but for a particular demo scenario I also want to make an explicit call to

WL.Client.connect( ... );

如果我使用http连接,则会看到类似以下的请求:

If I use an http connection I see a request like this:

http://192.168.0.19/MyApp/apps/services/api/Work01/ipad/init

,效果很好.相反,如果我使用SSL连接,如预期的那样,我会看到

and it works just fine. If instead I use an SSL connection, as expected I see this

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连接需要身份验证的整体含义?

That "request it with a version parameter" is intriguing. Is there some extra parameter I need to pass? Or is the overall implication that connecting over SSL requires authentication?

推荐答案

我遇到了同样的问题.

I had the same problem.

我已经通过在WL应用中使用服务器的真实IP地址而不是使用本地主机来解决了此问题:

I have solved it by using the real IP address of the server in the WL app instead of using localhost:

  1. 模拟器运行您的应用程序时,按菜单按钮.
  2. 选择更改您的服务器URL
  3. 删除"localhost"并使用IP地址.
  4. 接受并重试.

这解决了我的问题.

这篇关于使用SSL的Worklight 6.0应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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