I developed a iOS app that connects to a internal web server. When I used the simulator, it works fine, but when I build the same app on a iPhone, it gives me a error message “an ssl error has occurred and a secure connection to the server cannot be made. " Why the error only occurs on iPhone not in simulator?
Here is my environment Xcode 8.2 iOS 10.3 Objective C -- My client code is using ATS by default AFNetworking Framework 3.1 Web Server -- Support TLS 1.2 only Web Server Cert is not supporting forward secrecy yet.
Could it be because that my Cert is not ATS compliant?
After I read this document from Apple
<key>NSAppTransportSecurity</key>
<dict>
<key>NSExceptionDomains</key>
<dict>
<key>Your Domain</key>
<dict>
<key>NSIncludesSubdomains</key>
<true/>
<key>NSThirdPartyExceptionRequiresForwardSecrecy</key>
<false/>
</dict>
</dict>
</dict>
My app is now working on devices. My cert on the server is not Forward Secrecy ready yet.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With