Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateRootCA ¶
func GenerateRootCA() (*x509.Certificate, *rsa.PrivateKey, error)
GenerateRootCA generates a self-signed Root CA cert and key
func SaveCA ¶
func SaveCA(cert *x509.Certificate, key *rsa.PrivateKey, certPath, keyPath string) error
SaveCA saves the CA cert and key to files
Types ¶
type CA ¶
type CA struct {
Cert *x509.Certificate
Key *rsa.PrivateKey
}
CA represents a Certificate Authority
func (*CA) SignCertificate ¶
func (c *CA) SignCertificate(host string) (*x509.Certificate, *rsa.PrivateKey, error)
SignCertificate signs a new certificate for a specific host using the Root CA
Click to show internal directories.
Click to hide internal directories.