ssoauth

package
v1.11.0-beta3 Latest Latest
Warning

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

Go to latest
Published: Nov 18, 2021 License: MPL-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	// common for type=oidc and type=jwt
	JWTSupportedAlgs    []string          `json:",omitempty"`
	BoundAudiences      []string          `json:",omitempty"`
	ClaimMappings       map[string]string `json:",omitempty"`
	ListClaimMappings   map[string]string `json:",omitempty"`
	OIDCDiscoveryURL    string            `json:",omitempty"`
	OIDCDiscoveryCACert string            `json:",omitempty"`

	// just for type=jwt
	JWKSURL              string        `json:",omitempty"`
	JWKSCACert           string        `json:",omitempty"`
	JWTValidationPubKeys []string      `json:",omitempty"`
	BoundIssuer          string        `json:",omitempty"`
	ExpirationLeeway     time.Duration `json:",omitempty"`
	NotBeforeLeeway      time.Duration `json:",omitempty"`
	ClockSkewLeeway      time.Duration `json:",omitempty"`
	// contains filtered or unexported fields
}

Config is the collection of all settings that pertain to doing OIDC-based authentication and direct JWT-based authentication processes.

type Validator

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

Validator is the wrapper around the go-sso library that also conforms to the authmethod.Validator interface.

func NewValidator

func NewValidator(logger hclog.Logger, method *structs.ACLAuthMethod) (*Validator, error)

func (*Validator) Name

func (v *Validator) Name() string

Name implements authmethod.Validator.

func (*Validator) NewIdentity

func (v *Validator) NewIdentity() *authmethod.Identity

NewIdentity implements authmethod.Validator.

func (*Validator) Stop

func (v *Validator) Stop()

Stop implements authmethod.Validator.

func (*Validator) ValidateLogin

func (v *Validator) ValidateLogin(ctx context.Context, loginToken string) (*authmethod.Identity, error)

ValidateLogin implements authmethod.Validator.

Jump to

Keyboard shortcuts

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