ca

package
v1.1.4 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2020 License: MPL-2.0, MPL-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Store adapter

Store is the package state variable which contains database connections

Functions

func DownloadSshCA

func DownloadSshCA(w http.ResponseWriter, r *http.Request)

func GenerateTempSSHCert

func GenerateTempSSHCert(username, orgID string) (string, string, error)

func GetAllCAs

func GetAllCAs(w http.ResponseWriter, r *http.Request)

GetAllCAs returns all CAs of an organization

func GetHttpCADetail

func GetHttpCADetail(w http.ResponseWriter, r *http.Request)

GetHttpCADetail returns HTTP CA details

func GetSSHCerts

func GetSSHCerts(serviceID, orgID string) (hostc, caHost, caUser string)

func InitCA

func InitCA(w http.ResponseWriter, r *http.Request)

InitCA initialises HTTP CA of given type

func InitSSHCA

func InitSSHCA(w http.ResponseWriter, r *http.Request)

InitSSHCA creates SSH CA of given type

func InitStore

func InitStore(state *global.State)

InitStore initialises package state

func InitStoreMock

func InitStoreMock() *cryptMock

InitStoreMock will init mock state of this package

func UploadCA

func UploadCA(w http.ResponseWriter, r *http.Request)

UploadCA uploads new HTTP CA from user

Types

type CertHolderResponse

type CertHolderResponse struct {
	CertID   string                `json:"certID"`
	OrgID    string                `json:"orgID"`
	EntityID string                `json:"entityID"`
	Cert     *certinfo.Certificate `json:"cert"`
	// CertificateType should be constant representing CA, intermediate CA or Service(for http?) cert others
	CertType    string `json:"certType"`
	CreatedAt   int64  `json:"createdAt"`
	LastUpdated int64  `json:"lastUpdated"`
}

Jump to

Keyboard shortcuts

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