NSAppTransportSecurity???

Hello ,

I'm new in development.


I built an application that also to the objective to propose a Additional information on services to merchants who have a website.


I tested a lot of codes but the https /

does not allow any sites ! and seeking a tutorial proposed this method that works on info.plist

is this code:


<key> NSAppTransportSecurity < / key>

< dict >

<key> NSAllowsArbitraryLoads < / key>

<true />

< / dict >


My question:

am I allowed to make use of this feature ?

Thanks for your help


I tested a lot of codes but the https // does not allow any sites ! and seeking a tutorial proposed this method that works on

Answered by Paddy007 in 90807022

Hi DeepWill,


Yes it is allow to use this feature.


Paddy

Accepted Answer

Hi DeepWill,


Yes it is allow to use this feature.


Paddy

Great, thank you.

am I allowed to make use of this feature ?

Yes, but I strongly recommend that you should restrict your use of

NSAllowsArbitraryLoads
to situations where you really need it. For more information, see the resources referenced by App Transport Security.

Share and Enjoy

Quinn "The Eskimo!"
Apple Developer Relations, Developer Technical Support, Core OS/Hardware

let myEmail = "eskimo" + "1" + "@apple.com"

By default, When I build my project, the below content generated in the info.plist.


<key>NSAppTransportSecurity</key>

<dict><key>NSExceptionDomains</key>

<dict><key>localhost</key><dict>

<key>NSExceptionAllowsInsecureHTTPLoads</key><true/></dict></dict>

<key>NSAllowsArbitraryLoads</key>

<true/>

</dict>


I'm using a HTTPS connection and I want to enable the ATS. I changed the plist via xcode 10 like below.

<key>NSAppTransportSecurity</key>

<dict><key>NSAllowsArbitraryLoads</key><false/></dict>


I'm getting error like "failed to load webpage with error: the resource could not be loaded because the app transport security policy requires the use of a secure connection." Could you help me in this issue?

This is a really old thread, and much has changed in the ATS world since then. My advice:

  1. Read through my App Transport Security pinned post to come up to speed on those developments.

  2. If you’re still having problem, open up a new thread in Core OS > Networking and we can discuss things there.

Share and Enjoy

Quinn “The Eskimo!”
Apple Developer Relations, Developer Technical Support, Core OS/Hardware

let myEmail = "eskimo" + "1" + "@apple.com"
NSAppTransportSecurity???
 
 
Q