IonicPush not working in iOS9?

Hey All,

We have been using Ionic Push while testing our app and happily were able to successfully use push notifications in both iOS and Android. We have upgraded two of our test devices to iOS9 and are no longer able to receive push notifications on only these two devices. All other iOS devices lower than 9 still work as does Android.

On some investigation it would appear that $ionicUser.identify() is failing when trying to identify the iOS9 users. We are using the exact same code for our other non iOS9 devices with success.

Is anyone else finding that Ionic cannot identify certain users. iOS9 being on the devices is the only distinction we can think of.

Any help would be greatly appreciated to allow us to launch our app.

So after some investigation I think I have found the solution. Firstly we updated our local version of the Ionic push service from GitHub: to the latest version (at time of writing this 0.1.13)

When we were making our call to the IdentifyUser Endpoint ( …) we saw that the SSL was not trusted. I can only assume this is due to the recent TLS requirement of iOS9 to use TLS secure connections of TLS 1.2 and above. The Certificate used to on the site appears to have been created with a now deprecated Signature algorithm (SHA-1 with RSA Encryption). Therefore UIWebView in iOS9 is preventing us hitting the endpoint.

So although we assumed as it was secured by TLS 1.2 this would work this appears not to be the case until Ionic updated their Certificate.

Therefore the fix is to apply to TLS patch highlighted by Max’s great post:

We initially didn’t wanted our app to only make secure TLS calls to endpoints but this is not going to be possible until Ionic update their certificate. However it is still encrypted with TLS 1.2 so it’s not completely unsafe.

Hope this helps others, the morale of the story apply the info.plist fix to allow arbitrary loads via the blog post above.

Hey, I added the TLS fix,
since ionic-service-push-client is deprecated I moved to ionic-platform-web-client.
IOS9 is still not working for me - any advice?

Hi sagivf

I’m afraid we are having the exact same problem. We are in the process of trying to move to ionic-platform-web-client and can’t get any of iOS push notifications working anymore.

When we try and call we are getting a 404.

Sorry I can’t help, considering abandoning using Ionic Push altogether as we have wasted so much time trying to get it working and keep it working.

Hey, I actually got it to work. Unfortunately IO8 isn’t working.
A lot of it was vodo - but definitely moving to ionic-platform-web-client might help.

The main issue that confused me was how to register and unregister users.
I recommend you look at the source code.
The documentation is very confusing - don’t use push.unregister, use user.addPushToken() and user.removePushToken.

As it happens a lot with Ionic - they deliver fast and creative features, but they never add the finishing touches and move on to changes and new features before stabilizing the old ones…

They are very responsive tough so I advise you use

@sagivf Sagiv, with your iOS 9 code working, did you ever read the notification.payload successfully? Having trouble with that now. From your recommendation it sounds like reading the source of ionic-platform-web-client may be the easiest way to troubleshoot - it doesn’t seem like there’s any documentation other than push from scratch. Thanks

Yee, all works so far…
IOS8 is also working - lots and lots of vodo magic…