Skip to content

Instantly share code, notes, and snippets.

@jbsmith86
jbsmith86 / cert_vaildation
Last active April 18, 2018 18:30
This script returns the number of days left for validity of the certificate of a given url. Supports wildcard certs and SNI. Useful for monitoring.
#!/usr/bin/env ruby
require "optparse"
require "socket"
require "openssl"
require "time"
options = {
'port' => 443
}