Ibm mobilefirst 无法为iOS调用适配器

Ibm mobilefirst 无法为iOS调用适配器,ibm-mobilefirst,worklight-adapters,worklight-server,mobilefirst-server,mobilefirst-studio,Ibm Mobilefirst,Worklight Adapters,Worklight Server,Mobilefirst Server,Mobilefirst Studio,我使用的是IBM Worklight 6.2版。我制作了一个混合应用程序。我能够制作和部署.apk文件,并且运行良好。但当我为iPhone添加环境时。我以X代码导入该文件夹并运行该项目文件。应用程序运行正常,但我无法从适配器获得响应。下面是我得到的例外 The Error is of 403 saying: establishSSLClientAuth isCertificateExists: false 我的X代码版本是6.1 请帮我解决这个问题 2016-05-17 12:40:42.2

我使用的是IBM Worklight 6.2版。我制作了一个混合应用程序。我能够制作和部署
.apk
文件,并且运行良好。但当我为iPhone添加环境时。我以X代码导入该文件夹并运行该项目文件。应用程序运行正常,但我无法从适配器获得响应。下面是我得到的例外

The Error is of 403 saying: establishSSLClientAuth isCertificateExists:  false
我的X代码版本是6.1

请帮我解决这个问题

2016-05-17 12:40:42.277 mServe[683:138427] [DEBUG] [NONE] establishSSLClientAuth
2016-05-17 12:40:42.284 mServe[683:138394] [WARN] [USER_CERT_AUTH] +[WLUserAuthManager getCertificateIdentifier] in WLUserAuthManager.m:68 :: Certificate Identifier Key: com.worklight.userenrollment.certificate:com.mServe
2016-05-17 12:40:42.301 mServe[683:138394] THREAD WARNING: ['UserAuth'] took '17.668701' ms. Plugin should use a background thread.
2016-05-17 12:40:42.305 mServe[683:138477] [DEBUG] [NONE] Request [http://10.1.54.101:10080/Android/apps/services/api/mServe/iphone/query]
2016-05-17 12:40:42.310 mServe[683:138427] [DEBUG] [NONE] establishSSLClientAuth isCertificateExists:  false
2016-05-17 12:40:42.488 mServe[683:138394] [ERROR] [WL_AFHTTPCLIENTWRAPPER_PACKAGE] -[WLAFHTTPClientWrapper requestFailed:error:] in WLAFHTTPClientWrapper.m:216 :: Request Failed
2016-05-17 12:40:42.494 mServe[683:138394] [ERROR] [WL_AFHTTPCLIENTWRAPPER_PACKAGE] -[WLAFHTTPClientWrapper requestFailed:error:] in WLAFHTTPClientWrapper.m:217 :: Response Status Code : 403
2016-05-17 12:40:42.500 mServe[683:138394] [ERROR] [WL_AFHTTPCLIENTWRAPPER_PACKAGE] -[WLAFHTTPClientWrapper requestFailed:error:] in WLAFHTTPClientWrapper.m:218 :: Response Error : Expected status code in (200-299), got 403

您可能正在使用iOS 9。iOS 9默认使用一种称为ATS(应用程序传输安全)的新安全措施。在开发过程中,您可以禁用它以使网络请求成功通过

请看这里:

实际上,您需要在Xcode中通过添加以下内容来编辑应用程序的.plist文件:

<key>NSAppTransportSecurity</key>
<dict>
  <key>NSExceptionDomains</key>
  <dict>
    <key>localhost</key>
    <dict>
      <!--Include to allow HTTP requests-->
      <key>NSTemporaryExceptionAllowsInsecureHTTPLoads</key>
      <true/>
    </dict>
  </dict>
</dict>
NSAppTransportSecurity
NSExceptionDomains
本地服务器
NSTemporary ExceptionalLowsInSecureHttpLoads

您可能正在使用iOS 9。iOS 9默认使用一种称为ATS(应用程序传输安全)的新安全措施。在开发过程中,您可以禁用它以使网络请求成功通过

请看这里:

实际上,您需要在Xcode中通过添加以下内容来编辑应用程序的.plist文件:

<key>NSAppTransportSecurity</key>
<dict>
  <key>NSExceptionDomains</key>
  <dict>
    <key>localhost</key>
    <dict>
      <!--Include to allow HTTP requests-->
      <key>NSTemporaryExceptionAllowsInsecureHTTPLoads</key>
      <true/>
    </dict>
  </dict>
</dict>
NSAppTransportSecurity
NSExceptionDomains
本地服务器
NSTemporary ExceptionalLowsInSecureHttpLoads

Hi Idan,谢谢你的回复,但我没有使用iOS 9,我使用的是iOS 7。我真的不知道为什么会出现这个错误。我也在iOS 9中用你给定的解决方案尝试了这个,但它不起作用。(嗨,Idan,谢谢你的回答,但我没有用iOS 9,我用的是iOS 7。我真的不知道为什么会出现这个错误。我也在iOS 9中用你给定的解决方案尝试了这个,但它不起作用。)(你能从设备日志中发布更多信息吗。