bootstrap

package
v0.33.2 Latest Latest
Warning

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

Go to latest
Published: Jun 2, 2020 License: Apache-2.0 Imports: 40 Imported by: 8

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func LoadSignerFromFile

func LoadSignerFromFile(fn string) (string, crypto.Signer, error)

LoadSignerFromFile loads a private-key for signing

Supports JSON (JWK/JWS) and PEM

func LoadValidatorFromFile

func LoadValidatorFromFile(fn string) (string, crypto.PublicKey, error)

LoadValidatorFromFile loads a public-key used for validation.

Supported formats are JSON-JWK and PEM

Types

type Bootstrap

type Bootstrap interface {
	Config() *config.Config
	Managers() *managers.Managers
}

Bootstrap is a data structure to hold configuration required to start konnectd.

func Boot

func Boot(ctx context.Context, bsConf *Config, serverConf *config.Config) (Bootstrap, error)

Boot is the main entry point to bootstrap the konnectd service after validating the given configuration. The resulting Bootstrap struct can be used to retrieve configured identity-managers and their respective http-handlers and config.

This function should be used by consumers which want to embed konnect as a library.

type Config

type Config struct {
	Iss                            string
	IdentityManager                string
	URIBasePath                    string
	SignInURI                      string
	SignedOutURI                   string
	AuthorizationEndpointURI       string
	EndsessionEndpointURI          string
	Insecure                       bool
	TrustedProxy                   []string
	AllowScope                     []string
	AllowClientGuests              bool
	AllowDynamicClientRegistration bool
	EncryptionSecretFile           string
	Listen                         string
	IdentifierClientDisabled       bool
	IdentifierClientPath           string
	IdentifierRegistrationConf     string
	IdentifierScopesConf           string
	SigningKid                     string
	SigningMethod                  string
	SigningPrivateKeyFiles         []string
	ValidationKeysPath             string
	CookieBackendURI               string
	CookieNames                    []string
	AccessTokenDurationSeconds     uint64
	IDTokenDurationSeconds         uint64
	RefreshTokenDurationSeconds    uint64
}

Config is a typed application config which represents the user accessible config params

Jump to

Keyboard shortcuts

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