Home > Backend Development > PHP Tutorial > How to Resolve PHP cURL Error Code 60: SSL Certificate Issues on Windows?

How to Resolve PHP cURL Error Code 60: SSL Certificate Issues on Windows?

Patricia Arquette
Release: 2024-10-26 11:13:02
Original
351 people have browsed it

How to Resolve PHP cURL Error Code 60: SSL Certificate Issues on Windows?

PHP cURL Error Code 60: Troubleshooting SSL Certificate Issues

When setting up a PHP environment on Windows using WAMP and integrating the Amazon PHP SDK, you may encounter error code 60 in cURL. This error indicates an SSL certificate problem, specifically an inability to obtain the local issuer certificate.

To resolve this issue, verify that the following settings in your php.ini file are correct:

curl.cainfo = C:\Windows\ca-bundle.crt
Copy after login

However, the provided certificate may not be sufficient. Consider using the following trusted certificate root certificate bundle instead:

https://curl.haxx.se/ca/cacert.pem
Copy after login

Download this certificate bundle to your disk and update your php.ini file to point to its location:

curl.cainfo = "path_to_cert\cacert.pem"
Copy after login

Once the correct certificate is referenced, restart your WAMP service. This should resolve the SSL certificate problem and allow you to successfully run your PHP script.

The above is the detailed content of How to Resolve PHP cURL Error Code 60: SSL Certificate Issues on Windows?. For more information, please follow other related articles on the PHP Chinese website!

source:php
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Articles by Author
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template