auth

package
v0.0.0-...-bfb5f8b Latest Latest
Warning

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

Go to latest
Published: Jun 15, 2019 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConfigureAuthentication

func ConfigureAuthentication(authentication map[string]interface{})

func Login

func Login(c data.Client, msg map[string]interface{}) (*data.Player, error)

Types

type Authentication

type Authentication interface {
	Authenticate(data.Client, map[string]interface{}) (*data.Player, error)
}

type LDAPAuth

type LDAPAuth struct {
	Addr           string `json:"addr"`
	BaseDN         string `json:"baseDN"`
	Filter         string `json:"filter"`
	Network        string `json:"network"`
	UsernameFormat string `json:"usernameFormat"`
	Email          string `json:"email"`
	FirstName      string `json:"firstName"`
	FullName       string `json:"FullName"`
}

func NewLDAPAuth

func NewLDAPAuth(config json.RawMessage) (LDAPAuth, error)

type TrustedAuth

type TrustedAuth struct{}

func NewTrustedAuth

func NewTrustedAuth() (TrustedAuth, error)

func (TrustedAuth) Authenticate

func (auth TrustedAuth) Authenticate(c data.Client, msg map[string]interface{}) (*data.Player, error)

Jump to

Keyboard shortcuts

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