Environment: node6.10.1 Cordova 6.x, Ionic 2.2.1
App built with Cordova/ionic our API address to use HTTPS, after the security encryption, follow the normal process, packaging, and then run to the iOS real computer.
Then request login, will find an error:
Nsurlsession/nsurlconnection HTTP Load failed (Kcfstreamerrordomainssl,-9824)
Solution Ideas:
Check the CONFIG. archive file under the app's root directory.
There is a configuration:
<access origin= "*"/>
This configuration allows the app to access all the links. This configuration becomes a configuration in Info.plist after the project is compiled into an iOS project:
<key>nsapptransportsecurity</key>
<dict>
<key>nsallowsarbitraryloads</key>
<true/>
</dict>
That is to allow all links to access. Generally includes HTTP,HTTPS two kinds of access methods.
Under normal circumstances, if not submitted to the app Store, but the enterprise internal use, without auditing, the security requirements are not high, you can
Cordova Internal API with SSL HTTPS, error