Created
October 16, 2018 08:21
-
-
Save sudhirpandey/eaa596eccef59010a482ca53d7adb6ab to your computer and use it in GitHub Desktop.
commn opensssl commands
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#download certificate | |
echo -n | openssl s_client -connect server:port | sed -ne '/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p' > /tmp/server.cert | |
#verify cert against CA | |
openssl verify -verbose -CAfile /etc/pki/ca-trust/source/anchors/<ca>.crt /tmp/server.cert | |
#inspect cert to see issuer | |
openssl x509 -in /tmp/server.crt -text -noout |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment