mocks

package
v0.41.0 Latest Latest
Warning

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

Go to latest
Published: Jun 26, 2026 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrMissingCACert indicates missing ca certificate
	ErrMissingCACert = errors.New("missing ca certificate for certificate signing")

	// ErrFailedCertCreation indicates failed to certificate creation
	ErrFailedCertCreation = errors.New("failed to create client certificate")

	// ErrFailedCertRevocation indicates failed certificate revocation
	ErrFailedCertRevocation = errors.New("failed to revoke certificate")
)

Functions

func NewCertsRepository

func NewCertsRepository() certs.Repository

Types

type Agent added in v0.32.1

type Agent interface {
	// IssueCert is a mock method for Issuing Certificates of PKI Agent.
	IssueCert(cn, ttl, keyType string, keyBits int) (certs.Cert, error)

	// VerifyCert is a mock method for Verifying Certificates of PKI Agent.
	VerifyCert(certPEM string) (*x509.Certificate, error)

	// GenerateCRL is a mock method for generating CRL of PKI Agent.
	GenerateCRL(revokedSerials []pki.RevokedSerial) ([]byte, error)
}

func NewPKIAgent added in v0.32.1

func NewPKIAgent(tlsCert tls.Certificate, caCert *x509.Certificate, keyBits int, ttl string, timeout time.Duration) Agent

Jump to

Keyboard shortcuts

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