Llg Llg - 1 year ago 119
iOS Question

iOS 10: HTTP connection is not allowed

Trying to connected my swift application to the server in order to get the data, I got this error when I tested the app in the simulator and the device having iOS 10:

subsystem: com.apple.libsqlite3, category: logging, enable_level: 0, persist_level: 0, default_ttl: 0, info_ttl: 0, debug_ttl: 0, generate_symptoms: 0, enable_oversize: 1, privacy_setting: 2, enable_private_data: 0

and also this:

App Transport Security has blocked a cleartext HTTP (http://) resource load since it is insecure. Temporary exceptions can be configured via your app's Info.plist file.

I was first thinking that the problem is with the

so I added this to my info.plist:


But It has no effect at all for the iOS 10 (I don't know about the iOS 9 because I didn't tested it).

Note that my application works perfectly with iOS 8. I'm using Xcode 8 and swift 3.

Answer Source

You have to replace


with your own domain, and without 'http://'

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download