Documentation ¶
Overview ¶
Package certificate loads Push Services certificates exported from your Keychain in Personal Information Exchange format (*.p12).
If you prefer to use *.PEM files, you can of course use tls.LoadX509KeyPair or tls.X509KeyPair from the standard library.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrExpired = errors.New("certificate has expired or is not yet valid")
)
Certificate errors
Functions ¶
func Decode ¶
func Decode(p12 []byte, password string) (tls.Certificate, error)
Decode and verify an in memory .p12 certificate (DER binary format).
func Load ¶
func Load(filename, password string) (tls.Certificate, error)
Load a .p12 certificate from disk.
func TopicFromCert ¶ added in v0.6.0
func TopicFromCert(cert tls.Certificate) string
TopicFromCert extracts topic from a certificate's common name.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.