estserver

package
v0.0.7 Latest Latest
Warning

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

Go to latest
Published: Feb 25, 2022 License: MPL-2.0 Imports: 31 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func HTTPToContext

func HTTPToContext(logger log.Logger) httptransport.RequestFunc

func MakeHTTPHandler

func MakeHTTPHandler(service estService.Service, verify utils.Utils, logger log.Logger, cfg configs.Config, otTracer stdopentracing.Tracer, ctx context.Context) http.Handler

func NewEstService

func NewEstService(lamassuCaClient *lamassuca.LamassuCaClient, verifyUtils *utils.Utils, devicesDb devicesStore.DB, minReenrollDays int, logger log.Logger) lamassuest.Service

Types

type EstService

type EstService struct {
	// contains filtered or unexported fields
}

func (*EstService) CACerts

func (s *EstService) CACerts(ctx context.Context, aps string, r *http.Request) ([]*x509.Certificate, error)

func (*EstService) Enroll

func (*EstService) Health

func (s *EstService) Health(ctx context.Context) bool

func (*EstService) Reenroll

func (*EstService) ServerKeyGen

func (s *EstService) ServerKeyGen(ctx context.Context, csr *x509.CertificateRequest, aps string, r *http.Request) (*x509.Certificate, []byte, error)

type EstServiceI

type EstServiceI interface {
	Health(ctx context.Context) bool
	CACerts(ctx context.Context, aps string, r *http.Request) ([]*x509.Certificate, error)
	Enroll(ctx context.Context, csr *x509.CertificateRequest, aps string, cert *x509.Certificate, r *http.Request) (*x509.Certificate, error)
	Reenroll(ctx context.Context, cert *x509.Certificate, csr *x509.CertificateRequest, aps string, r *http.Request) (*x509.Certificate, error)
	ServerKeyGen(ctx context.Context, csr *x509.CertificateRequest, aps string, r *http.Request) (*x509.Certificate, []byte, error)
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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