Documentation
¶
Overview ¶
Package pki provides functions for managing a public key infrastructure (PKI), including certificate authority (CA) operations, certificate issuance, and revocation.
Index ¶
- func AutoCert(url, email, sans, dsPath string, insecure bool) error
- func CreateCA(req *datastore.CreateCAReq) error
- func CreateCertificate(csr []byte) ([]byte, error)
- func CreateCertificateRequest(req *CSRReqEnt) ([]byte, error)
- func DestroyCA()
- func GetAcmeServerStatus() string
- func GetHTTPServerStatus() string
- func IsCAValid() bool
- func Start(ctx context.Context, wg *sync.WaitGroup) error
- type AutoCertUser
- type CSRReqEnt
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateCA ¶
func CreateCA(req *datastore.CreateCAReq) error
func CreateCertificate ¶
CreateCertificate manually issues a certificate from a given CSR.
func GetAcmeServerStatus ¶
func GetAcmeServerStatus() string
func GetHTTPServerStatus ¶ added in v1.56.0
func GetHTTPServerStatus() string
Types ¶
type AutoCertUser ¶
type AutoCertUser struct {
Email string
Registration *registration.Resource
// contains filtered or unexported fields
}
func (*AutoCertUser) GetEmail ¶
func (u *AutoCertUser) GetEmail() string
func (*AutoCertUser) GetPrivateKey ¶
func (u *AutoCertUser) GetPrivateKey() crypto.PrivateKey
func (AutoCertUser) GetRegistration ¶
func (u AutoCertUser) GetRegistration() *registration.Resource
type CSRReqEnt ¶
type CSRReqEnt struct {
KeyType string `json:"KeyType"`
CommonName string `json:"CommonName"`
OrganizationalUnit string `json:"OrganizationalUnit"`
Organization string `json:"Organization"`
Locality string `json:"Locality"`
Province string `json:"Province"`
Country string `json:"Country"`
Sans string `json:"Sans"`
}
Click to show internal directories.
Click to hide internal directories.