Bash: calculating number of days till certificate expiration using openssl
The openssl utility can be used to show the details of a certificate, including its ‘Not After’ expiration date in string format. This can be transformed into “how many days till expiration” with a bit of Bash date math. Create test certificate and key Using a line provided by Diego Woitasen for non-interactive self-signed certification … Bash: calculating number of days till certificate expiration using openssl