SUPPORT.TWILIO.COM END OF LIFE NOTICE: This site, support.twilio.com, is scheduled to go End of Life on February 27, 2024. All Twilio Support content has been migrated to help.twilio.com, where you can continue to find helpful Support articles, API docs, and Twilio blog content, and escalate your issues to our Support team. We encourage you to update your bookmarks and begin using the new site today for all your Twilio Support needs.

Twilio PHP helper library SSL certificate problem on Windows

When using the Twilio PHP Helper Library on Windows, you may receive an error similar to the following:

Fatal error: Uncaught exception 'Services_Twilio_TinyHttpException' with message 'SSL certificate problem: self signed certificate in certificate chain'

The php_curl library on Windows doesn't use an up-to-date list of CA Root Certificates. You can get a pem file of the root certificates from the curl site below.

To fix this issue please try the following:

1. Download the following pem file: https://curl.haxx.se/ca/cacert.pem

2. Copy this file to c:\cert\cacert.pem

3. Open php.ini file in your favorite editor (see here for where to find it)

4. If the following configuration string: curl.cainfo exists in your php.ini, please uncomment it by removing ";" and modify the path in order to point it to the cacert.pem file you downloaded, e.g:

;;;;;;;;;;;;;;;;;;;
; Module Settings ;
;;;;;;;;;;;;;;;;;;;
curl.cainfo=c:\cert\cacert.pem

5. Restart your Apache or IIS service to apply the change.

Have more questions? Submit a request
Powered by Zendesk