openssl s_client -showcerts -connect mail.m2rocks.de:993 -servername mail.m2rocks.de 2>/dev/null | openssl x509 -noout -dates
Show the valid timespan for a mailserver tls certificate
Published: 25.08.2025 | 45 Words | 1 minutesThis bash/ fish command will print the time a tls cert of a mailserver (smtp) is valid.
To view the whole cert chain use:
openssl s_client -showcerts -connect mail.m2rocks.de:993 -servername mail.m2rocks.de 2>/dev/null