OpenSSL commands To get the server certificates that are used during the HTTPS connection initiation, run the following commands: openssl s_client -showcerts -connect : < /dev/null > openssl x509 -inform PEM -in -text -out openssl s_client -showcerts -connect www.google.com:443 < /dev/null > outfile openssl x509 -inform PEM -in outfile -text -out cdata