我们已经实施了混合移动应用程序,该应用程序使用最新版本的MFP 7.0,也是服务器端。使用Xcode7在Mac上运行应用程序并在iOS9模拟器中测试,但在进行登录操作时失败。试图登录时与连接相关的异常发生
我们使用原生代码可以访问内部防火墙,然后通过WL.Client.connect连接到WL服务器,我们看到了一些例外,打印出的Xcode的控制台如下:
2015-10-07 19:16:48.320 TestApp[7608:514098] [DEBUG] [WL_AFHTTPCLIENTWRAPPER_PACKAGE] -[WLAFHTTPClientWrapper requestFailed:error:] in WLAFHTTPClientWrapper.m:335 :: Response Status Code : 403 2015-10-07 19:16:48.322 TestApp[7608:514098] [DEBUG] [WL_AFHTTPCLIENTWRAPPER_PACKAGE] -[WLAFHTTPClientWrapper requestFailed:error:] in WLAFHTTPClientWrapper.m:336 :: Response Error : Expected status code in (200-299), got 403
2015-10-07 19:16:48.323 TestApp[7608:514098] [ERROR] [WL_REQUEST] -[WLRequest requestFailed:error:] in WLRequest.m:477 :: Status code='403' error='Expected status code in (200-299), got 403' response='/-secure- {"reason":"App authenticity security check failed"}/' 2015-10-07 19:16:48.323 TestApp[7608:514098] [DEBUG] [WL_REQUEST] -[WLRequest requestFailed:error:] in WLRequest.m:480 :: Response Header: { Connection = "Keep-Alive"; "Content-Language" = "en-US"; "Content-Type" = "application/json; charset=UTF-8"; Date = "Wed, 07 Oct 2015 11:16:44 GMT"; "Keep-Alive" = "timeout=10, max=97"; "Transfer-Encoding" = Identity; "X-Powered-By" = "Servlet/3.0"; }
响应数据:
/-secure- {"reason":"App authenticity security check failed"}/ 2015-10-07 19:16:53.064 TestApp[7608:514605] [ERROR] [NONE] [/apps/services/api/TestApp/iphone/init] failure. state: 200, response: undefined 2015-10-07 19:16:53.064 TestApp[7608:514170] [DEBUG] [NONE] Client registration failed with error: {"status":200,"responseHeaders":{},"responseText":"The operation couldn’t be completed. (WL_AUTH error 0.)","invocationContext":null}
1)什么是您的MobileFirst Studio版本**和内部版本号**? 2)您是否使用错误日志中显示的真实性?它是基本的真实性还是扩展的真实性? 3)你是否禁用了Xcode项目中的Bitcode? 4)您是否禁用ATS或将您的开发服务器列入白名单进行连接会起作用? –
1)MFP的版本为20150907-1450 – djw
3)xcode中的位代码被禁用 4)ATS也被禁用。 – djw