Updating Your Apache Cordova / Ionic App to work with Apple’s iOS 9

Updating your Apache Cordova app to work with iOS 9 comes with some difficulties surrounding the new App Transport Security implementation. The end goal for this requirement is better security for app user’s, which is excellent. However, we ran into some problems when attempting to get our app ready to go.

We found that our Cordova platform’s iOS version was unable to be updated past 3.9.1 as that was the latest available in NPM, and the new Cordova Whitelist plugin (version 1.1.0) required Cordova iOS platform 4.0. We ended up forcing the installation of the plugin to 1.0.0 via the command:

You also need to ensure that you are defining your whitelisted rule set within your config.xml and including a meta tag in your index.html. This is an example of what you might want to use:

Apache Cordova Plugin Whitelist Documentation (GitHub)

We found that we still weren’t able to make remote requests to API end points that we needed to. To ensure this would work we needed to add the following code to the platforms/ios/[AppName]/appname-Info.plist file.

Leave a Reply

Your email address will not be published. Required fields are marked *