Applies to:
Mac OSX mostly
Other Systems and Software using SSL
PHP CURL
Summary
When you execute PHP CURL calls to HTTPS URLs, you might get the error:
SSL certificate problem: unable to get local issuer certificate
This means that the root certificates on the system are invalid.
Solution
You can fix the system certificate, deploy valid SSL root certificate to the system, or only to Zend Server PHP.
As kindly suggested by Peter Carlsson, here is a short recipe to fix PHP-CURL with working local certificate:
1. Downloaded cacert.pem from http://curl.haxx.se/ca/cacert.pem
2. Copy cacert.pem to '/usr/local/zend/etc/ssl/certs/'
3. Modify CURL configuration (Zend Server Configuration -> PHP -> CURL) and change:
curl.cainfo = '/usr/local/zend/etc/ssl/certs/cacert.pem'
4. Restart PHP and check if CURL can read from HTTPS URL.
REF: https://blog.digicert.com/expired-intermediate-certificate/
Comments