duo

package
v0.6.0-rebuild Latest Latest
Warning

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

Go to latest
Published: Jun 14, 2016 License: MPL-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Package duo provides a Duo MFA handler to authenticate users with Duo. This handler is registered as the "duo" type in mfa_config.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DuoHandler

func DuoHandler(req *logical.Request, d *framework.FieldData, resp *logical.Response) (
	*logical.Response, error)

DuoHandler interacts with the Duo Auth API to authenticate a user login request. If successful, the original response from the login backend is returned.

func DuoPaths

func DuoPaths() []*framework.Path

DuoPaths returns path functions to configure Duo.

func DuoRootPaths

func DuoRootPaths() []string

DuoRootPaths returns the paths that are used to configure Duo.

Types

type AuthClient

type AuthClient interface {
	Preauth(options ...func(*url.Values)) (*authapi.PreauthResult, error)
	Auth(factor string, options ...func(*url.Values)) (*authapi.AuthResult, error)
}

func GetDuoAuthClient

func GetDuoAuthClient(req *logical.Request, config *DuoConfig) (AuthClient, error)

type DuoAccess

type DuoAccess struct {
	SKey string `json:"skey"`
	IKey string `json:"ikey"`
	Host string `json:"host"`
}

type DuoConfig

type DuoConfig struct {
	UsernameFormat string `json:"username_format"`
	UserAgent      string `json:"user_agent"`
}

func GetDuoConfig

func GetDuoConfig(req *logical.Request) (*DuoConfig, error)

Jump to

Keyboard shortcuts

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