provider

package
v1.11.23 Latest Latest
Warning

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

Go to latest
Published: Mar 21, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Provider

type Provider interface {
	// PrepareKey creates/setup up a private key for use with the provider
	PrepareKey(string) (crypto.PrivateKey, error)

	// AttestationData returns the attestation data that can be used in the ZTS api
	AttestationData(string, crypto.PrivateKey, *signature.SignatureInfo) (string, error)

	// GetName returns the name of the current provider
	GetName() string

	// GetHostname returns the name of the hostname as recognized by the provider
	GetHostname() string

	// GetCsrDn returns the x.509 Distinguished Name for use in the CSR
	GetCsrDn() pkix.Name

	// GetSanDns returns an array of provider specific SAN DNS entries
	GetSanDns(string, bool, bool, []string) []string

	// GetSanUri returns an array of provider specific SAN URI entries
	GetSanUri(string, ip.Opts) []*url.URL

	// GetEmail retuns an array of one email which can be used to identify the principal
	GetEmail(string) []string

	// GetRoleDnsNames returns an array of SanDNS entries that can be used for Role Cert
	GetRoleDnsNames(*x509.Certificate, string) []string

	// GetSanIp returns an array of IPs that can be included in San IPs from the list of IPs found on the box
	GetSanIp(map[string]bool, []net.IP, ip.Opts) []net.IP

	// GetSuffix returns the suffix for the current provider
	GetSuffix() string
}

Provider is the interface which wraps various Providers known to ZTS It has methods for providing attestationdata depending on provider type and generating sub-parts of DN to be including in the CSR and San DNS and URI entries

Jump to

Keyboard shortcuts

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