challenge

package
v2.7.1+incompatible Latest Latest
Warning

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

Go to latest
Published: Jul 22, 2019 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// HTTP01 is the "http-01" ACME challenge https://tools.ietf.org/html/draft-ietf-acme-acme-16#section-8.3
	// Note: ChallengePath returns the URL path to fulfill this challenge
	HTTP01 = Type("http-01")

	// DNS01 is the "dns-01" ACME challenge https://tools.ietf.org/html/draft-ietf-acme-acme-16#section-8.4
	// Note: GetRecord returns a DNS record which will fulfill this challenge
	DNS01 = Type("dns-01")

	// TLSALPN01 is the "tls-alpn-01" ACME challenge https://tools.ietf.org/html/draft-ietf-acme-tls-alpn-05
	TLSALPN01 = Type("tls-alpn-01")
)

Variables

This section is empty.

Functions

func FindChallenge

func FindChallenge(chlgType Type, authz acme.Authorization) (acme.Challenge, error)

func GetTargetedDomain

func GetTargetedDomain(authz acme.Authorization) string

Types

type Provider

type Provider interface {
	Present(domain, token, keyAuth string) error
	CleanUp(domain, token, keyAuth string) error
}

Provider enables implementing a custom challenge provider. Present presents the solution to a challenge available to be solved. CleanUp will be called by the challenge if Present ends in a non-error state.

type ProviderTimeout

type ProviderTimeout interface {
	Provider
	Timeout() (timeout, interval time.Duration)
}

ProviderTimeout allows for implementing a Provider where an unusually long timeout is required when waiting for an ACME challenge to be satisfied, such as when checking for DNS record propagation. If an implementor of a Provider provides a Timeout method, then the return values of the Timeout method will be used when appropriate by the acme package. The interval value is the time between checks.

The default values used for timeout and interval are 60 seconds and 2 seconds respectively. These are used when no Timeout method is defined for the Provider.

type Type

type Type string

Type is a string that identifies a particular challenge type and version of ACME challenge.

func (Type) String

func (t Type) String() string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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