ca

package
v0.0.0-...-46c9509 Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2021 License: MIT Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Init

func Init(configPath, trusteePath, outPath string) error

Types

type CAConfig

type CAConfig struct {
	KeyThreshold  int      `json:"key_threshold" yaml:"key_threshold"`
	KeyShares     int      `json:"key_shares" yaml:"key_shares"`
	KeyBits       int      `json:"key_bits" yaml:"key_bits"`
	Expires       string   `json:"expires" yaml:"expires"`
	Organization  string   `json:"organization" yaml:"organization"`
	OU            string   `json:"organizational_unit" yaml:"organizational_unit"`
	Country       string   `json:"country" yaml:"country"`
	State         string   `json:"state" yaml:"state"`
	Locality      string   `json:"locality" yaml:"locality"`
	CN            string   `json:"common_name" yaml:"common_name"`
	PermitDomains []string `json:"permit_domains" yaml:"permit_domains"`
	// contains filtered or unexported fields
}

func (*CAConfig) Load

func (c *CAConfig) Load(content []byte) error

Load loads the config content

func (*CAConfig) Validate

func (c *CAConfig) Validate() error

type CertRequest

type CertRequest struct {
	Key          string `json:"key" yaml:"key"`
	CSR          string `json:"csr" yaml:"csr"`
	KeyBits      int    `json:"key_bits" yaml:"key_bits"`
	Organization string `json:"organization" yaml:"organization"`
	OU           string `json:"organizational_unit" yaml:"organizational_unit"`
	Country      string `json:"country" yaml:"country"`
	State        string `json:"state" yaml:"state"`
	Locality     string `json:"locality" yaml:"locality"`
	CN           string `json:"common_name" yaml:"common_name"`
	IP           string `json:"ip" yaml:"ip"`
	Domain       string `json:"domain" yaml:"domain"`
	URI          string `json:"uri" yaml:"uri"`
}

func (*CertRequest) Load

func (c *CertRequest) Load(content []byte) error

func (*CertRequest) NewCSR

func (c *CertRequest) NewCSR(stdout bool) error

NewCSR creates a new certificate signing request

type Request

type Request struct {
	ID        string       `yaml:"id" json:"id"`
	PublicKey string       `yaml:"public_key" json:"public_key"`
	Request   *CertRequest `yaml:"request" json:"request"`
}

type Response

type Response struct {
	ID               string `yaml:"id" json:"id"`
	EncryptedKeypart string `yaml:"encrypted_keypart" json:"encrypted_keypart"`
}

Jump to

Keyboard shortcuts

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