Versions in this module Expand all Collapse all v0 v0.0.1 Mar 19, 2024 Changes in this version + const EC256 + const EC384 + const RSA2048 + const RSA4096 + const RSA8192 + var Default = &Config + func CheckConfig(c *Config) error + func ListenAndServeTLS(addr string, handler http.Handler, mail string, cleanup func(), ...) error + func ListenAndServeTLSCustom(addr string, handler http.Handler, cfg *Config, tlsconf *tls.Config, ...) error + func ListenAndServeTLSLocal(addr string, handler http.Handler, cleanup func(), domains ...string) error + func Redirect(w http.ResponseWriter, req *http.Request) + type CR struct + CSR []byte + CertStableURL string + CertURL string + Certificate []byte + Domain string + IssuerCertificate []byte + PrivateKey []byte + type CertReloader struct + func Init(cfg *Config, cleanup func()) (*CertReloader, error) + func NewCertReloader(certPath, keyPath string, logFile *os.File, cleanup func()) (*CertReloader, error) + func (reloader *CertReloader) GetCertificateFunc() func(*tls.ClientHelloInfo) (*tls.Certificate, error) + func (reloader *CertReloader) ReloadNow() + type CertStatus struct + Domains []string + Expires int + RenewBefore int + func Status() *CertStatus + type Config struct + CacheDir string + CacheDirPerm os.FileMode + CheckInterval time.Duration + DNSProvider string + DNSServers []string + DidRenewCertificate func() + DirectoryURL string + Domains []string + FailedToRenewCertificate func(error) + HTTPAddress string + KeyType string + Local bool + RenewBefore int + SSLEmail string + TLSAddress string + UpdateHosts bool + WillRenewCertificate func() + type KeyType string + type SSLUser struct + Email string + Key *rsa.PrivateKey + Registration *registration.Resource + func (u SSLUser) GetEmail() string + func (u SSLUser) GetPrivateKey() crypto.PrivateKey + func (u SSLUser) GetRegistration() *registration.Resource