oidc

package
v0.24.1 Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2019 License: Apache-2.0 Imports: 19 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 {
	Keyring    keyring.Keyring
	NonceStore nonce.Store
}

Config provides necessary parameters for OIDC authentication.

type Provider

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

Provider implements the auth.IdentityProvider interface by acting as a relying-party to a standard OIDC server.

func NewProvider

func NewProvider(ctx context.Context, cfg Config) (*Provider, error)

NewProvider prepares a new Provider with the given config.

func (*Provider) ExtractIdentity

func (p *Provider) ExtractIdentity(route *auth.RouteInfo, w http.ResponseWriter, req *http.Request) (*auth.Identity, error)

ExtractIdentity will return a redirect error for new auth requests, and provide a users identity for callback requests.

func (*Provider) Info

func (p *Provider) Info(ctx context.Context) auth.ProviderInfo

Info returns the appropriate auth.ProviderInfo based on configuration.

As OIDC requires no user input, only the Title is provided.

Jump to

Keyboard shortcuts

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