Obtain SSL certificate Information before redirect

If you need to know information on a web ssl certificate, but the accompaning URL redirects inmediately, it can be difficult to optain that information. Here’s how you do it in the CLI:

openssl s_client -connect foo.example.com:443 < /dev/null | openssl x509 -text