Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to connect: tls://gateway.sandbox.push.apple.com:2195 #95

Closed
joskoomen opened this issue Jan 16, 2016 · 4 comments
Closed

Unable to connect: tls://gateway.sandbox.push.apple.com:2195 #95

joskoomen opened this issue Jan 16, 2016 · 4 comments

Comments

@joskoomen
Copy link

Probably an easy fix that i just don't see:

  • I've created my certificates for iOS, generated .pem files like described here: http://www.apptuitions.com/generate-pem-file-for-push-notification/
  • Stored my certificate on the server with CHMOD 400
  • edit config with path to the right .pem file with the right passphrase
  • Setup a test call in a laravel 5.2 rest api call with my own device token

But with both development certificate and production certificate i get this error when trying this api call in my browser. Maybe it's because i'm using the browser, i'm not sure..

Unable to connect: tls://gateway.sandbox.push.apple.com:2195: 2 (stream_socket_client(): Unable to set local cert chain file "my/path/to/my/file.pem"; Check that your cafile/capath settings include details of your certificate and its issuer)

@joskoomen
Copy link
Author

Fixed it:

2 problems:

  • I had (by advice of someone else) the CHMOD on 400 this must be 640 this solved this authentication fix
  • My token included capitals. That's not supported yet? Made my tokens all lowercase..

@faisalahsan
Copy link

faisalahsan commented Jun 25, 2017

@joskoomen
I am still facing same issue.
1 - My file have CHMOD 777
2 - My tokens are in lowercase.
Any idea?

@joskoomen
Copy link
Author

@faisalahsan try to set chmod to 640.

On the other hand, i started to use an external service for my notifications.
Although this project works pretty good. You should take a look at https://onesignal.com/
Free to use and easy to install and connect (through an api)

@faisalahsan
Copy link

@joskoomen thanks for your reply.
But I am not allow to use any kind of service.
Still using same problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants