Wednesday, July 4, 2012

Verify expiry date of SSL Certificate using OpenSSL


Connect to the server using s_client and download the certificate to cert.txt
openssl s_client -connect server:port > cert.txt

Verify the expiry date from the downloaded certificate
openssl x509 -in cert.txt -noout -enddate 

Friday, June 15, 2012

Speed up SSH connections using ControlMaster

It is possible to speed up ssh connections from the same host by using ControlMaster. What we need is establish a ControlMaster connection to the host and all the subsequent connection from the same host will be allowed with out prompting for passwords.

The configuration required is simple. Just create a file ~/.ssh/config and add the contents provided below.

vi ~/.ssh/config
Host *
ControlPath ~/.ssh/master-%r@%h:%p
ControlMaster auto


For more information refer man page

man 5 ssh_config