0

I'm trying to some code using REST API in Wordpress locally, but get this error

cURL error 60: SSL certificate problem: self signed certificate

My understanding is I need to add the SSL certificate to Keychain, but I can't. When I try to add it Keychain asks form my admin login, and then nothing happens.

I'm on an M1 Mac running 11.4

milky_jay
  • 378
  • 1
  • 6
  • 17
  • Does this answer your question? [How to fix curl: (60) SSL certificate: Invalid certificate chain](https://stackoverflow.com/questions/18964175/how-to-fix-curl-60-ssl-certificate-invalid-certificate-chain) – Bram Aug 25 '21 at 12:14
  • @Bram Thanks, that that will add a certificate for that specific URL, I need to add one for the localhost – milky_jay Aug 31 '21 at 00:50
  • Then your URL is `https://localhost` and the above mentioned question still applies. Have you tried opening your website on Safari and performing the steps in the question? Have you manually added your certificate to the keychain? Is the certificate in your Keychain? – Bram Aug 31 '21 at 07:15
  • Yes, as outlined in the question I have tired adding it to keychain, but nothing happens – milky_jay Sep 01 '21 at 02:06

1 Answers1

0

Check this answer about how to setup https for localhost.

enter image description here enter image description here

Cristi Maris
  • 1,329
  • 22
  • 21