config

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Nov 15, 2026 License: Apache-2.0 Imports: 14 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidCertificateAuthorityURL     = errors.New("invalid certificate authority URL")
	ErrInvalidIssuer                      = errors.New("invalid issuer")
	ErrInvalidRedirectURL                 = errors.New("invalid redirect URL")
	ErrInvalidScopes                      = errors.New("invalid scopes")
	ErrInvalidTrustedCertificateAuthority = errors.New("invalid trusted ca")

	ErrMissingCertificateAuthorityURL     = errors.New("missing certificate authority URL")
	ErrMissingClientID                    = errors.New("missing client ID")
	ErrMissingIssuer                      = errors.New("missing issuer")
	ErrMissingRedirectURL                 = errors.New("missing redirect URL")
	ErrMissingTrustedCertificateAuthority = errors.New("missing trusted ca")

	ErrUnknownKey = errors.New("unknown configuration key")
)

Functions

func ConfigPath added in v0.21.0

func ConfigPath() string

Types

type ClientConfig added in v0.21.0

type ClientConfig struct {
	CertificateAuthorityURL     string   `json:"ca_url"`
	ClientID                    string   `json:"client_id"`
	Issuer                      string   `json:"issuer"`
	RedirectURL                 string   `json:"redirect_url"`
	Scopes                      []string `json:"scopes"`
	TrustedCertificateAuthority string   `json:"trusted_ca"`
	// contains filtered or unexported fields
}

func LoadClientConfig added in v0.21.0

func LoadClientConfig(configpath string) (*ClientConfig, error)

Loads client config from the following sources on Windows:

  • Registry (HKCU or HKLM - defaults to HKLM)
  • Policy ("HKLM\Software\Policies\Serverless SSH CA Client")

And the following on non-Windows platforms:

  • YAML based configuration file

func NewClientConfig added in v0.25.1

func NewClientConfig(conf ClientConfig) (*ClientConfig, error)

NewClientConfig validates conf and returns it ready to use, for callers that build the config in code rather than loading it with LoadClientConfig. No defaults are applied.

func (*ClientConfig) CertificateAuthorityPublicKey added in v0.21.0

func (c *ClientConfig) CertificateAuthorityPublicKey() ssh.PublicKey

Jump to

Keyboard shortcuts

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