Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type AuthConfig ¶
type AuthConfig struct { Password *AuthPassword `json:"password" toml:"password" yaml:"password"` LDAP *AuthLDAP `json:"ldap" toml:"ldap" yaml:"ldap"` }
AuthConfig contains the authentication configuration for web interface
type AuthLDAP ¶
type AuthLDAP struct { Host string `json:"host" toml:"host" yaml:"host"` // address to connect to Port int `json:"port" toml:"port" yaml:"port"` // port to connect to Method string `json:"method" toml:"method" yaml:"method"` // connect method (SSL/TLS) Domain string `json:"domain" toml:"domain" yaml:"domain"` // binddn Filter string `json:"filter" toml:"filter" yaml:"filter"` // binddn BindDN string `json:"binddn" toml:"binddn" yaml:"binddn"` // binddn TLSConfig tlsconfig.TLSConfig `json:"tls" toml:"tls" yaml:"tls"` // contains filtered or unexported fields }
AuthLDAP is the provider for LDAP based authentication for the web service
type AuthPassword ¶
AuthPassword is the provider for Password based authentication for the web service
func NewAuthPassword ¶
func NewAuthPassword(users map[string]string) *AuthPassword
NewAuthPassword provides a authentication provider for Passwords
func (*AuthPassword) VerifyLogin ¶
func (a *AuthPassword) VerifyLogin(username, password string) (bool, error)
VerifyLogin validates a user/password combination and returns true or false accordingly
Click to show internal directories.
Click to hide internal directories.