Documentation
¶
Index ¶
- func KeyFuncFromCertDir(directory string) (jwt.Keyfunc, error)
- func KeyFuncFromPEMBytes(pemBytes []byte) (jwt.Keyfunc, error)
- func KeyFuncFromPEMFile(fileLocation string) (jwt.Keyfunc, error)
- func PEMBytesToCert(pemBytes []byte) (*x509.Certificate, error)
- func PEMDirToCertMap(directory string) (map[string]*x509.Certificate, error)
- func PEMFileToCert(fileLocation string) (*x509.Certificate, error)
- type Client
- type Config
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func KeyFuncFromPEMBytes ¶
KeyFuncFromPEMBytes returns a closure which in turn returns the public part of the JWT certificate from a file.
func KeyFuncFromPEMFile ¶
KeyFuncFromPEMFile returns a closure which in turn returns the public part of the JWT certificate from a file.
func PEMBytesToCert ¶
func PEMBytesToCert(pemBytes []byte) (*x509.Certificate, error)
PemBytesToKey turns a set of PEM bytes into a x509 certificate
func PEMDirToCertMap ¶
func PEMDirToCertMap(directory string) (map[string]*x509.Certificate, error)
PEMDirToCertMap takes a directory as input and turns it into a map of certificates.
func PEMFileToCert ¶
func PEMFileToCert(fileLocation string) (*x509.Certificate, error)
PEMFileToCert turns a file location into a certificate.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client is the basic struct for this client.
func (*Client) Authenticate ¶
Authenticate is a jwt wrapper that returns the JWT token to be used on subsequent calls.
func (*Client) RetrieveToken ¶
RetrieveToken checks to see if the token we have is still valid, re-authenticates if necessary and returns the token.
func (*Client) StillValid ¶
StillValid checks to see if the token we have is still valid.