A mas de unos no has pasado este error, por que olvidamos simplemente agregar una excepcion a nuestro projecto sobre conexiones «No seguras», aunque es una buena practica en algun momento necesitamos hacer excepciones y habilitar estos dominios como excepciones.
"The resource could not be loaded because the App Transport Security policy requires the use of a secure connection."
"The resource could not be loaded because the App Transport Security policy requires the use of a secure connection."
"The resource could not be loaded because the App Transport Security policy requires the use of a secure connection."
Para simplemente permitir cualquier conexión HTTP desde nuestro proyecto Xcode simplemente tendremos que agregar esto a nuestro archivo «info.plist»
NSAppTransportSecurity Dictionary
NSAllowsArbitraryLoads true
NSAppTransportSecurity Dictionary
NSAllowsArbitraryLoads true
NSAppTransportSecurity Dictionary NSAllowsArbitraryLoads true

NSAllowsArbitraryLoads

NSAppTransportSecurity
Algo que podremos hacer tambien, es colocar excepciones por dominios, digamos que necesitamos hacer llamadas HTTP a un solo dominio en particular.
De esta forma esta agregando solo llamadas HTTP al dominio google.com y sus subdominios:
<key>NSAppTransportSecurity</key>
<dict>
<key>NSAllowsArbitraryLoads</key>
<false/>
<key>NSExceptionDomains</key>
<dict>
<key>google.com</key>
<dict>
<key>NSExceptionAllowsInsecureHTTPLoads</key>
<true/>
<key>NSIncludesSubdomains</key>
<true/>
</dict>
</dict>
</dict>
<key>NSAppTransportSecurity</key>
<dict>
<key>NSAllowsArbitraryLoads</key>
<false/>
<key>NSExceptionDomains</key>
<dict>
<key>google.com</key>
<dict>
<key>NSExceptionAllowsInsecureHTTPLoads</key>
<true/>
<key>NSIncludesSubdomains</key>
<true/>
</dict>
</dict>
</dict>
<key>NSAppTransportSecurity</key> <dict> <key>NSAllowsArbitraryLoads</key> <false/> <key>NSExceptionDomains</key> <dict> <key>google.com</key> <dict> <key>NSExceptionAllowsInsecureHTTPLoads</key> <true/> <key>NSIncludesSubdomains</key> <true/> </dict> </dict> </dict>
