Documentation ¶
Overview ¶
Package testing provides easy to use methods for creating certificates using a Root CA or individual.
Index ¶
- func CreateCertificateAndPrivateKeyForTesting(hostnameList []string) ([]byte, []byte, error)
- func CreateDerivedCertificateAndPrivateKeyForTesting(rootPublicCertificateData []byte, rootPrivateKeyData []byte, ...) ([]byte, []byte, error)
- func CreateRootCertificateAndPrivateKeyForTesting(hostnameList []string) ([]byte, []byte, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateCertificateAndPrivateKeyForTesting ¶
CreateCertificateAndPrivateKeyForTesting is for generating test certificates in unit tests.
func CreateDerivedCertificateAndPrivateKeyForTesting ¶
func CreateDerivedCertificateAndPrivateKeyForTesting(rootPublicCertificateData []byte, rootPrivateKeyData []byte, hostnameList []string) ([]byte, []byte, error)
CreateDerivedCertificateAndPrivateKeyForTesting creates a certificate rooted in the Root certificate from CreateRootCertificateAndPrivateKeyForTesting().
func CreateRootCertificateAndPrivateKeyForTesting ¶
CreateRootCertificateAndPrivateKeyForTesting creates a Root CA certificate that can be used as the parent from certificate-private key pairs created from CreateDerivedCertificateAndPrivateKeyForTesting.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.