signer

package
v0.0.0-...-32d7a98 Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type KeySigner

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

KeySigner does the work of signing a ssh public key with the CA key.

func New

func New(pemBytes, passPhrase []byte) (*KeySigner, error)

New unseal CA key by passphrase

func (*KeySigner) SignKey

func (s *KeySigner) SignKey(req *SignRequest) (string, error)

SignKey sign user key and return certificate as string

type SignRequest

type SignRequest struct {
	CertType   string    `json:"cert_type"`
	Key        string    `json:"key"`
	Username   string    `json:"username"`
	Hostnames  string    `json:"hostnames"`
	ValidUntil time.Time `json:"valid_until"`
}

SignRequest pass information for sign

Jump to

Keyboard shortcuts

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