Skip to content

Instantly share code, notes, and snippets.

@bxm
Last active September 18, 2019 10:13
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 bxm/5aabe81cd49fb954fa192fd9cdab1e2c to your computer and use it in GitHub Desktop.
Save bxm/5aabe81cd49fb954fa192fd9cdab1e2c to your computer and use it in GitHub Desktop.
View SSL validity dates for a list of servers
for SERVER in server{1..3}.example.com ; do
echo -e "\n${SERVER}\n"
echo | timeout 1s openssl s_client -connect ${SERVER}:443 2>/dev/null \
| openssl x509 -noout -dates 2>/dev/null
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment