Laravel 5 Socialite - cURL error 77: error setting certificate verify locations
I got stuck on this problem as well. It turned out that I had the path to my certificate set incorrectly in my php.ini file. Forgot the .txt extension.
What I had:
curl.cainfo = "C:\xampp\php\cacert.pem"
What I changed it to:
curl.cainfo = "C:\xampp\php\cacert.pem.txt"
Hope this helps.
Add cacert.pem file from https://curl.haxx.se/ca/cacert.pem in c:\xampp\php\cacert.pem
Change setting in php.ini file:
curl.cainfo = "C:\xampp\php\cacert.pem
My error is:
cURL error 77: error setting certificate verify locations: CAfile: C:\xampp\apache\bin\curl-ca-bundle.crt CApath: none (see http://curl.haxx.se/libcurl/c/libcurl-errors.html)
This works well for me:
- Download the certificate from: https://curl.haxx.se/ca/cacert.pem
- Rename the cacert.pem file into curl-ca-bundle.crt
- Copy the file into path/to/xampp/apache/bin
- Restart apache
- Save this certificate (https://curl.haxx.se/ca/cacert.pem) as
cacert.pem.txt
inC:\xampp\php
-
Add to
php.ini
:curl.cainfo = "C:\xampp\php\cacert.pem.txt"
- Don't forget to restart XAMPP (it won't work until it restarts)
Then it works fine!