api

package
v0.22.2-rc9 Latest Latest
Warning

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

Go to latest
Published: Oct 1, 2022 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Overview

Package api implements a SCEP HTTP server.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Get added in v0.20.0

func Get(w http.ResponseWriter, r *http.Request)

Get handles all SCEP GET requests

func New deprecated

func New(auth *scep.Authority) api.RouterHandler

New returns a new SCEP API router.

Deprecated: use scep.Route(r api.Router)

func Post added in v0.20.0

func Post(w http.ResponseWriter, r *http.Request)

Post handles all SCEP POST requests

func Route added in v0.20.0

func Route(r api.Router)

Route traffic and implement the Router interface.

Types

type Response added in v0.20.0

type Response struct {
	Operation   string
	CACertNum   int
	Data        []byte
	Certificate *x509.Certificate
	Error       error
}

Response is a SCEP server Response.

func GetCACaps added in v0.20.0

func GetCACaps(ctx context.Context) (Response, error)

GetCACaps returns the CA capabilities in a SCEP response

func GetCACert added in v0.20.0

func GetCACert(ctx context.Context) (Response, error)

GetCACert returns the CA certificates in a SCEP response

func PKIOperation added in v0.20.0

func PKIOperation(ctx context.Context, req request) (Response, error)

PKIOperation performs PKI operations and returns a SCEP response

Jump to

Keyboard shortcuts

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