Documentation
¶
Index ¶
- Constants
- func SaveToEncoder(enc auth.Encoder, a *Authenticator) (err error)
- func SaveToFile(path string, a *Authenticator) (err error)
- func SaveToStream(w io.Writer, a *Authenticator) (err error)
- type Authenticator
- func (a *Authenticator) AddPermission(cred auth.Credentials, domain string) (err error)
- func (a *Authenticator) Close() (err error)
- func (a *Authenticator) Load(config Config) (err error)
- func (a *Authenticator) RemovePermission(user string, domain string) (err error)
- func (a *Authenticator) Save() (Config, error)
- func (a *Authenticator) Shutdown(ctx context.Context) error
- func (a *Authenticator) VerifyPermissions(cred auth.Credentials, domain string) (err error)
- type Config
- type PermissionTable
- type UserTable
Constants ¶
View Source
const SimpleAuth = auth.Type("simpleauth")
Variables ¶
This section is empty.
Functions ¶
func SaveToEncoder ¶ added in v0.1.46
func SaveToEncoder(enc auth.Encoder, a *Authenticator) (err error)
func SaveToFile ¶ added in v0.1.46
func SaveToFile(path string, a *Authenticator) (err error)
func SaveToStream ¶ added in v0.1.46
func SaveToStream(w io.Writer, a *Authenticator) (err error)
Types ¶
type Authenticator ¶ added in v0.1.46
type Authenticator struct {
Permissions PermissionTable
}
func LoadFromDecoder ¶ added in v0.1.46
func LoadFromDecoder(dec auth.Decoder) (a *Authenticator, err error)
func LoadFromFile ¶ added in v0.1.46
func LoadFromFile(path string) (a *Authenticator, err error)
func LoadFromStream ¶ added in v0.1.46
func LoadFromStream(r io.Reader) (a *Authenticator, err error)
func New ¶ added in v0.1.46
func New(config Config) (a *Authenticator, err error)
func (*Authenticator) AddPermission ¶ added in v0.1.46
func (a *Authenticator) AddPermission(cred auth.Credentials, domain string) (err error)
func (*Authenticator) Close ¶ added in v0.1.46
func (a *Authenticator) Close() (err error)
func (*Authenticator) Load ¶ added in v0.1.46
func (a *Authenticator) Load(config Config) (err error)
func (*Authenticator) RemovePermission ¶ added in v0.1.46
func (a *Authenticator) RemovePermission(user string, domain string) (err error)
func (*Authenticator) Save ¶ added in v0.1.46
func (a *Authenticator) Save() (Config, error)
func (*Authenticator) Shutdown ¶ added in v0.1.46
func (a *Authenticator) Shutdown(ctx context.Context) error
func (*Authenticator) VerifyPermissions ¶ added in v0.1.46
func (a *Authenticator) VerifyPermissions(cred auth.Credentials, domain string) (err error)
type Config ¶ added in v0.0.64
type Config struct {
Permissions PermissionTable
}
type PermissionTable ¶
Click to show internal directories.
Click to hide internal directories.