certificates

package
v0.7.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 27, 2023 License: MIT Imports: 8 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CertClient

type CertClient interface {
	InitCa() error
	GenerateKeyAndCertSet(hosts []string, validityInDays int) ([]byte, []byte, error)
	PemEncodedCa() []byte
}

func NewCertGeneratorClient

func NewCertGeneratorClient(organizations []string, caValidity int) (CertClient, error)

type CertificateGenerator

type CertificateGenerator struct {
	CaValidity    int
	Ca            *x509.Certificate
	CaPrivateKey  *rsa.PrivateKey
	CaPem         []byte
	CaPrivKeyPem  []byte
	Organizations []string
}

func (*CertificateGenerator) GenerateKeyAndCertSet

func (c *CertificateGenerator) GenerateKeyAndCertSet(hosts []string, validityInDays int) ([]byte, []byte, error)

func (*CertificateGenerator) InitCa

func (c *CertificateGenerator) InitCa() error

func (*CertificateGenerator) PemEncodedCa

func (c *CertificateGenerator) PemEncodedCa() []byte

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL