 Documentation
      ¶
      Documentation
      ¶
    
    
  
    
  
    Index ¶
Constants ¶
This section is empty.
Variables ¶
      View Source
      
  
var ( // ErrNoCredentials indicates no recognizable credentials were supplied. ErrNoCredentials = errors.New("access: no credentials provided") // ErrInvalidCredential signals that supplied credentials were rejected by a provider. ErrInvalidCredential = errors.New("access: invalid credential") // ErrNotHandled tells the manager to continue trying other providers. ErrNotHandled = errors.New("access: not handled") )
Functions ¶
func RegisterProvider ¶
func RegisterProvider(typ string, factory ProviderFactory)
RegisterProvider registers a provider factory for a given type identifier.
Types ¶
type Manager ¶
type Manager struct {
	// contains filtered or unexported fields
}
    Manager coordinates authentication providers.
func (*Manager) Authenticate ¶
Authenticate evaluates providers until one succeeds.
func (*Manager) SetProviders ¶
SetProviders replaces the active provider list.
type Provider ¶
type Provider interface {
	Identifier() string
	Authenticate(ctx context.Context, r *http.Request) (*Result, error)
}
    Provider validates credentials for incoming requests.
func BuildProvider ¶ added in v6.0.10
type ProviderFactory ¶
ProviderFactory builds a provider from configuration data.
 Click to show internal directories. 
   Click to hide internal directories.