In High Sierra, curl has switched from linking against SecureTransport, to use LibreSSL. However with this change, it seems that curl no longer recognises trusted certificates stored in the keychain.
# note that safari does not trust the site (expected)
$ open -a Safari https://self-signed.badssl.com/
# note that curl does not trust the site (expected)
$ curl https://self-signed.badssl.com
curl: (60) SSL certificate problem: self signed certificate
# trust the self-signed certificate by adding it to the keychain