Skip to content

Instantly share code, notes, and snippets.

@sangeeths
Created January 3, 2014 18:09
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 sangeeths/8243105 to your computer and use it in GitHub Desktop.
Save sangeeths/8243105 to your computer and use it in GitHub Desktop.
To get the server certificates that are used during the HTTPS connection initiation, run the following commands
OpenSSL commands
To get the server certificates that are used during the HTTPS connection initiation, run the following commands:
openssl s_client -showcerts -connect <hostname>:<port> < /dev/null > <outfile.txt>
openssl x509 -inform PEM -in <outfile.txt> -text -out <certificatefile.txt>
openssl s_client -showcerts -connect www.google.com:443 < /dev/null > outfile
openssl x509 -inform PEM -in outfile -text -out cdata
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment