openssl s_client -connect mail.example.com:443
openssl s_client -connect mail.example.com:443 | openssl x509 -text | grep DNS