K
K
Karina2015-12-24 01:03:44
PHP
Karina, 2015-12-24 01:03:44

How can push notification be sent on safari OS X?

I've had a problem for probably more than 4 days - I just can't send push to safari. deviceToken - I received from the site.
Checking the certificate:

openssl s_client -connect gateway.push.apple.com:2195 -cert apns-dev.pem -key apns-dev.pem

There is quite a lot of information there, but the main thing is the server - Entrust and Verify return code: 0 (ok) - in my opinion everything is fine with the certificate.
As for the code - I tried these libraries:
https://github.com/jwage/php-apns
https://github.com/richsage/RMSPushNotificationsBundle
and tried without libraries via stream_context_create() and stream_socket_client()
I probably won't give the code it is quite simple - it was taken from git'a from the above libraries and worked out without errors.
As for generating a certificate, I tried to generate it in two different ways:
stackoverflow.com/questions/6372308/apns-ssl-gatew...
and more sophisticated
vxtindia.com/blog/push-notifications-for-your-ipho...
I don't know where to look for the error and why I can't get a push. My site is in Safari's Notifications list. Selinux is disabled on the server.
Many thanks to everyone for any advice.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question