authorities

package
v0.0.0-...-8992e16 Latest Latest
Warning

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

Go to latest
Published: May 15, 2020 License: MIT Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Authority

type Authority interface {
	GetPublicKey() []byte
}

func LoadSSHAuthority

func LoadSSHAuthority(keydata []byte, pubkeydata []byte) (Authority, error)

func LoadTLSAuthority

func LoadTLSAuthority(keydata []byte, certdata []byte) (Authority, error)

type SSHAuthority

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

func (*SSHAuthority) GetPublicKey

func (d *SSHAuthority) GetPublicKey() []byte

func (*SSHAuthority) Sign

func (d *SSHAuthority) Sign(request string, ishost bool, lifespan time.Duration, keyid string, principals []string) (string, error)

type TLSAuthority

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

func (*TLSAuthority) Equal

func (t *TLSAuthority) Equal(authority *TLSAuthority) bool

func (*TLSAuthority) GetPrivateKey

func (t *TLSAuthority) GetPrivateKey() []byte

func (*TLSAuthority) GetPublicKey

func (t *TLSAuthority) GetPublicKey() []byte

func (*TLSAuthority) HasAttempt

func (t *TLSAuthority) HasAttempt(request *http.Request) bool

func (*TLSAuthority) Sign

func (t *TLSAuthority) Sign(request string, ishost bool, lifespan time.Duration, commonname string, names []string, organizations []string) (string, error)

func (*TLSAuthority) ToCertPool

func (t *TLSAuthority) ToCertPool() *x509.CertPool

func (*TLSAuthority) ToHTTPSCert

func (t *TLSAuthority) ToHTTPSCert() tls.Certificate

func (*TLSAuthority) Verify

func (t *TLSAuthority) Verify(request *http.Request) (string, error)

Jump to

Keyboard shortcuts

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