This repository has been archived on 2023-07-11. You can view files and clone it, but cannot push or open issues or pull requests.
nginx-ldap-auth/main/config.go

37 lines
849 B
Go
Raw Permalink Normal View History

2018-09-15 08:43:38 -04:00
package main
import "time"
type AuthConfig struct {
BindDN string `yaml:"bindDN"`
BindPW string `yaml:"bindPW"`
}
type UserConfig struct {
2018-09-15 09:10:30 -04:00
BaseDN string `yaml:"baseDN"`
2018-09-15 08:43:38 -04:00
Filter string `yaml:"filter"`
RequiredGroups []string `yaml:"requiredGroups"`
}
type GroupConfig struct {
2018-09-15 09:10:30 -04:00
BaseDN string `yaml:"baseDN"`
GroupAttr string `yaml:"groupAttr"`
2018-10-02 17:54:00 -04:00
Filter string `yaml:"filter"`
2018-09-15 08:43:38 -04:00
}
type TimeoutConfig struct {
Success time.Duration `yaml:"success"`
Wrong time.Duration `yaml:"wrong"`
}
type Config struct {
Web string `yaml:"web"`
2018-09-15 19:39:13 -04:00
Path string `yaml:"path"`
2018-10-02 18:00:27 -04:00
Message string `yaml:"message"`
2018-09-15 08:43:38 -04:00
Servers []string `yaml:"servers"`
Auth AuthConfig `yaml:"auth"`
User UserConfig `yaml:"user"`
Group GroupConfig `yaml:"group"`
Timeout TimeoutConfig `yaml:"timeout"`
}