

Public static bool canInitWithRequest (NSUrlRequest request) Then override the default delegate methods so that we can add our custom logic. Start by creating a new class and have it inherit from NSUrlProtocol. IOS is no longer blocking my webpage but we need a way to listen in to all requests our web view is making so we can work our magic with trusting the self signed certificate (remember this part is for dev releases only and not production). NSTemporaryExceptionAllowsInsecureHTTPLoads

This can be achieved by adding the following into your ist file: My advice is to turn off ATS for the only resources you trust. In my case a single domain. Yes, you may just be making the change for a quick test or prototype app, but it’s easy to forget you made the change and before you know it you’ve released an insecure app to your users. To resolve a problem with a blocked resource you can turn off ATS for you application with a single entry in your ist file. Whilst this is the simplest and quickest approach, my advice would be to avoid doing this.

The best way to resolve this issue is to ensure all resources are securely protected in the correct way, and therefore your application, and users data, is secure!īut this is not always possible! And if you’re like me then you have no choice but to step around the default ATS setting. NSURLSession/NSURLConnection HTTP load failed (kCFStreamErrorDomainSSL, -9802) Hide your IP address to browse the web privately & anonymously. Unblocks applications and websites from around the world. The only VPN that gives you simple direct access to your favorite censored or blocked websites. With the current application I’m working on I ran into trouble whilst loading a dev resource only to find it was using a self signed certificate and being blocked by the OS. I also had a requirement to inspect an Ajax web request and the WebView ShouldStartLoad delegate was not receiving these request callbacks.įirst things first, if your applications requests are being blocked you will see something like: Unlimited VPN Plus Unblock websites, apps, and content Keep your activities safe, secure and private. In iOS 9 Apple have turned on App Transport Security (ATS) as default. So if your iOS application is connecting to an insecure url resource then you’re out of luck as it will be blocked, an example of the most likely culprit is viewing a webpage without SSL encryption.
