1

I am trying to load images from amazon s3 (async).

But I get these errors in my log:

NSURLSession/NSURLConnection HTTP load failed (kCFStreamErrorDomainSSL,-9802)

I am making all my api calls with "https", it worked in ios 8.3 / xcode6

So

user2722667
  • 8,195
  • 14
  • 52
  • 100
  • Seems like you are having same issue : http://stackoverflow.com/questions/30778579/kcfstreamerrordomainssl-9802-when-connecting-to-a-server-by-ip-address-through – bpolat Sep 21 '15 at 22:39
  • possible duplicate of [Transport Security has Blocked a cleartext HTTP](http://stackoverflow.com/questions/31254725/transport-security-has-blocked-a-cleartext-http) – Jeef Sep 21 '15 at 23:51
  • You should take a look at a [post](https://mobile.awsblog.com/post/Tx2QM69ZE6BGTYX/Preparing-Your-Apps-for-iOS-9) on AWS Mobile Development Blog. – Yosuke Sep 22 '15 at 00:47

3 Answers3

2

Add the following to your info.plist exactly as typed.

NSAppTransportSecurity

Once you create that make its value a dictionary called

NSAllowsArbitraryLoads

Set the value to true or yes

Matodobra24
  • 55
  • 10
  • Thanks it worked! But is that enough? Looking at: https://mobile.awsblog.com/post/Tx2QM69ZE6BGTYX/Preparing-Your-Apps-for-iOS-9 they suggest to add some more stuff – Kiwo Tew Sep 22 '15 at 10:21
2

You are running into the HTTPS errors of App Transport Security read here: Transport security has blocked a cleartext HTTP

But the basic jist is add the following to your info.plist

<key>NSAppTransportSecurity</key>
<dict>
  <key>NSAllowsArbitraryLoads</key>
      <true/>
</dict>
Community
  • 1
  • 1
Jeef
  • 26,861
  • 21
  • 78
  • 156
  • Thanks it worked! But is that enough? Looking at: https://mobile.awsblog.com/post/Tx2QM69ZE6BGTYX/Preparing-Your-Apps-for-iOS-9 they suggest to add some more stuff – Kiwo Tew Sep 22 '15 at 10:22
0

You are running into the HTTPS errors of App Transport Security read here: Transport security has blocked a cleartext HTTP

But the basic jist is add the following to your info.plist

<key>NSAppTransportSecurity</key>
<dict>
  <key>NSAllowsArbitraryLoads</key>
      <true/>
</dict>

You can do that via a text editor or in XCODE as such:

enter image description here

Community
  • 1
  • 1
Jeef
  • 26,861
  • 21
  • 78
  • 156
  • Thanks it worked! But is that enough? Looking at: https://mobile.awsblog.com/post/Tx2QM69ZE6BGTYX/Preparing-Your-Apps-for-iOS-9 they suggest to add some more stuff – user2722667 Sep 22 '15 at 07:28