Java keytool easy way to add server cert from url/port
I have a server with a self signed certificate, but also requires client side cert authentication. I am having a rough time trying to get the raw CA server cert so I can import it into a keystore. Anyone have some suggestions on how to easily do that? Thanks. dnozay Was looking at how to trust a certificate while using jenkins cli, and found https://issues.jenkins-ci.org/browse/JENKINS-12629 which has some recipe for that. This will give you the certificate: openssl s_client -connect ${HOST}:${PORT} </dev/null if you are interested only in the certificate part, cut it out by piping it to: |