Created
July 10, 2013 10:29
-
-
Save mintsoft/5965253 to your computer and use it in GitHub Desktop.
Inspect Remote SSL Certificate using openssl
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
| #!/bin/bash | |
| [[ -n "${1}" ]] && openssl x509 -in <( echo "GET /" | openssl s_client -connect ${1}:443 2>&1 | grep -A 65535 'Server certificate' | tail -n+2 | grep -B 65535 'END CERTIFICATE' ) -noout -text -purpose |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment