Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CertPair ¶
type CertPair struct {
Key crypto.Signer
Cert *x509.Certificate
}
CertPair is a private key and certificate for use for client auth, as a CA, or serving.
type ClientInfo ¶
type ClientInfo struct {
// Name is the user name (embedded as the cert's CommonName)
Name string
// Groups are the groups to which this user belongs (embedded as the cert's
// Organization)
Groups []string
}
ClientInfo describes some Kubernetes user for the purposes of creating client certificates.
type TinyCA ¶
type TinyCA struct {
CA CertPair
// contains filtered or unexported fields
}
TinyCA supports signing serving certs and client-certs, and can be used as an auth mechanism with envtest.
func NewTinyCA ¶
NewTinyCA creates a new a tiny CA utility for provisioning serving certs and client certs FOR TESTING ONLY. Don't use this for anything else!
func (*TinyCA) NewClientCert ¶
func (c *TinyCA) NewClientCert(user ClientInfo) (CertPair, error)
NewClientCert produces a new CertPair suitable for use with Kubernetes client cert auth with an API server validating based on this CA.
Click to show internal directories.
Click to hide internal directories.