provisioners

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: Jul 4, 2024 License: BSD-3-Clause Imports: 8 Imported by: 0

Documentation

Overview

Package provisioners provides a mapping between CertificateRequest and the Cloudflare API, with credentials already bounded by an OriginIssuer.

Index

Constants

View Source
const (
	// The default validity duration, if not provided.
	DefaultDurationInternval = 7
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Provisioner

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

Provisioner allows for CertificateRequests to be signed using the stored Cloudflare API client.

func New

func New(client Signer, reqType v1.RequestType, log logr.Logger) (*Provisioner, error)

New returns a new provisioner.

func (*Provisioner) Sign

func (p *Provisioner) Sign(ctx context.Context, cr *certmanager.CertificateRequest) (certPem []byte, err error)

Sign uses the Cloduflare API to sign a CertificateRequest. The validity of the CertificateRequest is normalized to the closests validity allowed by the Cloudflare API, which make be significantly different than the validity provided.

type Signer added in v0.7.0

type Signer interface {
	Sign(ctx context.Context, req *cfapi.SignRequest) (*cfapi.SignResponse, error)
}

Signer implements the Origin CA signing API.

Jump to

Keyboard shortcuts

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