compactpki

package
v10.323.0+incompatible Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2021 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CompactPKI

type CompactPKI struct {
	// contains filtered or unexported fields
}

CompactPKI holds all PKI information

func NewCompactPKIWithTokenCA

func NewCompactPKIWithTokenCA(keyPEM []byte, certPEM []byte, caPEM []byte, trustedControllers []*secrets.ControllerInfo, txKey []byte, compress claimsheader.CompressionType) (*CompactPKI, error)

NewCompactPKIWithTokenCA creates new secrets for PKI implementation based on compact encoding.

keyPEM: is the private key that will be used for signing tokens formated as a PEM file.
certPEM: is the public key that will be used formated as a PEM file.
trustedControllers: is a list of trusted controllers.
txKey: is the public key that is send over the wire.
compressionType: is packed with the secrets to indicate compression.

func (*CompactPKI) AckSize

func (p *CompactPKI) AckSize() uint32

AckSize returns the default size of an ACK packet

func (*CompactPKI) CertAuthority

func (p *CompactPKI) CertAuthority() []byte

CertAuthority returns the cert authority

func (*CompactPKI) EncodingKey

func (p *CompactPKI) EncodingKey() interface{}

EncodingKey returns the private key

func (*CompactPKI) KeyAndClaims

func (p *CompactPKI) KeyAndClaims(pkey []byte) (interface{}, []string, time.Time, *pkiverifier.PKIControllerInfo, error)

KeyAndClaims returns both the key and any attributes associated with the public key.

func (*CompactPKI) PublicKey

func (p *CompactPKI) PublicKey() interface{}

PublicKey returns the public key

func (*CompactPKI) RPCSecrets

func (p *CompactPKI) RPCSecrets() secrets.RPCSecrets

RPCSecrets returns the secrets that are marshallable over the RPC interface.

func (*CompactPKI) TransmittedKey

func (p *CompactPKI) TransmittedKey() []byte

TransmittedKey returns the PEM of the public key in the case of PKI if there is no certificate cache configured

Jump to

Keyboard shortcuts

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