Add basic/digest auth
Signed-off-by: Emile Vauge <emile@vauge.com>
This commit is contained in:
parent
2a596b8162
commit
3a5b67a3e1
6 changed files with 156 additions and 81 deletions
|
@ -183,3 +183,22 @@ func (cs *Constraints) SetValue(val interface{}) {
|
|||
func (cs *Constraints) Type() string {
|
||||
return fmt.Sprint("constraint")
|
||||
}
|
||||
|
||||
// Auth holds authentication configuration (BASIC, DIGEST, users)
|
||||
type Auth struct {
|
||||
Basic *Basic
|
||||
Digest *Digest
|
||||
}
|
||||
|
||||
// Users authentication users
|
||||
type Users []string
|
||||
|
||||
// Basic HTTP basic authentication
|
||||
type Basic struct {
|
||||
Users
|
||||
}
|
||||
|
||||
// Digest HTTP authentication
|
||||
type Digest struct {
|
||||
Users
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue