auth

package
v0.0.0-...-5bbaa1a Latest Latest
Warning

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

Go to latest
Published: Nov 10, 2020 License: Apache-2.0 Imports: 2 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrAuthFailure          = errors.New("auth: Authentication failure")
	ErrAuthProviderNotFound = errors.New("auth: Authentication provider not found")
)

Functions

func Register

func Register(name string, provider Authenticator)

func Unregister

func Unregister(name string)

Types

type Authenticator

type Authenticator interface {
	Authenticate(id string, cred interface{}) error
}

type Manager

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

func NewManager

func NewManager(providerName string) (*Manager, error)

func (*Manager) Authenticate

func (this *Manager) Authenticate(id string, cred interface{}) error

Jump to

Keyboard shortcuts

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