Skip to content

Instantly share code, notes, and snippets.

@udhos
Last active September 20, 2021 18:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save udhos/0b2386d1615f8a8c9637644077fb350e to your computer and use it in GitHub Desktop.
Save udhos/0b2386d1615f8a8c9637644077fb350e to your computer and use it in GitHub Desktop.
curl_cacert

get ca cert

openssl s_client -showcerts -servername servername -connect servername:443 > /tmp/cacert.pem

show

openssl x509 -in /tmp/cacert.pem -text

use ca cert

curl --cacert /tmp/cacert.pem -d '{"a":"b"}' https://servername/test

Reference

https://curl.se/docs/sslcerts.html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment