auth

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Dec 28, 2018 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetEmail

func GetEmail(req *http.Request) string

Types

type Auth

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

func New

func New(db database, signingKey string, jwtExpire int) Auth

func (*Auth) GetAuthenticator

func (auth *Auth) GetAuthenticator(w http.ResponseWriter, req *http.Request)

func (*Auth) HandleDisableTwoFactor

func (auth *Auth) HandleDisableTwoFactor(w http.ResponseWriter, req *http.Request)

func (*Auth) HandleLogin

func (auth *Auth) HandleLogin(w http.ResponseWriter, req *http.Request)

func (*Auth) HandlePrelogin

func (auth *Auth) HandlePrelogin(w http.ResponseWriter, req *http.Request)

func (*Auth) HandleRegister

func (auth *Auth) HandleRegister(w http.ResponseWriter, req *http.Request)

func (*Auth) HandleTwoFactor

func (auth *Auth) HandleTwoFactor(w http.ResponseWriter, req *http.Request)

func (*Auth) JwtMiddleware

func (auth *Auth) JwtMiddleware(next http.Handler) http.Handler

func (*Auth) VerifyAuthenticatorSecret

func (auth *Auth) VerifyAuthenticatorSecret(w http.ResponseWriter, req *http.Request)

Jump to

Keyboard shortcuts

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