NSURLSession/NSURLConnection HTTP load failed on iOS 9

前端 未结 13 1065
爱一瞬间的悲伤
爱一瞬间的悲伤 2020-11-22 05:20

Tried to run my existing app on iOS9 but getting failure while using AFURLSessionManager.

__block NSURLSessionDataTask *task = [self.sessionMana         


        
相关标签:
13条回答
  • 2020-11-22 06:12

    This is what worked for me when I had this error:

    <key>NSAppTransportSecurity</key>
    <dict>
        <key>NSExceptionDomains</key>
        <dict>
            <key>example.com</key>
            <dict>
                <key>NSExceptionRequiresForwardSecrecy</key>
                <false/>
                <key>NSTemporaryExceptionAllowsInsecureHTTPLoads</key>
                <true/>
                <key>NSIncludesSubdomains</key>
                <true/>
                <key>NSTemporaryExceptionMinimumTLSVersion</key>
                <string>TLSv1.0</string>
            </dict>
        </dict>
    </dict>
    
    0 讨论(0)
提交回复
热议问题