Documentation ¶
Index ¶
- func CertGrabber(uri string, queue chan *CertificateInfo)
- func GenerateReport(certs CertificateInfoList, warningsOnly bool) string
- func GetCerts(host string, port int) *x509.Certificate
- func GetExpireDays(then time.Time) int
- func IsExpired(then time.Time) bool
- func MailReport(report, to_addr string)
- type CertificateInfo
- type CertificateInfoList
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CertGrabber ¶
func CertGrabber(uri string, queue chan *CertificateInfo)
Grab a certificate from the given uri and send it down a channel to be processed Then report our exit to the main thread using another channel This is intended to be run via a goroutine
func GenerateReport ¶
func GenerateReport(certs CertificateInfoList, warningsOnly bool) string
Given a Certificates list, create a tabular report of the relevant information in string format
func GetCerts ¶
func GetCerts(host string, port int) *x509.Certificate
Give a hostname and a port grab the certificate for the service running there
func GetExpireDays ¶
Get the number days until a certificate expires Calculated based on the time.Time the certificate expires
func MailReport ¶
func MailReport(report, to_addr string)
Give a report (just a string) and an adresss to send it to Send that report out via email
Types ¶
type CertificateInfo ¶
type CertificateInfo struct {
// contains filtered or unexported fields
}
type CertificateInfoList ¶
type CertificateInfoList []*CertificateInfo
func (CertificateInfoList) Len ¶
func (c CertificateInfoList) Len() int
The Len function for CertificateInfoList used as part of the implementation of sort.Interface
func (CertificateInfoList) Less ¶
func (c CertificateInfoList) Less(i, j int) bool
Calculate the order of 2 CertificateInfoList in a CertificateInfoList list used as part of the implementation of sort.Interface
func (CertificateInfoList) Swap ¶
func (c CertificateInfoList) Swap(i, j int)
Swap 2 elements in a CertificateInfoList type used as part of the implementation of sort.Interface