Log authentication failures to info debug level.
This commit is contained in:
parent
ae4bf50f7a
commit
4bdb88f4bc
1 changed files with 1 additions and 0 deletions
|
@ -674,6 +674,7 @@ func (s *server) Start() {
|
||||||
auth := "Basic " + base64.StdEncoding.EncodeToString([]byte(login))
|
auth := "Basic " + base64.StdEncoding.EncodeToString([]byte(login))
|
||||||
authhdr := r.Header["Authorization"]
|
authhdr := r.Header["Authorization"]
|
||||||
if len(authhdr) <= 0 || authhdr[0] != auth {
|
if len(authhdr) <= 0 || authhdr[0] != auth {
|
||||||
|
log.Infof("Frontend did not supply correct authentication.")
|
||||||
return errors.New("auth failure")
|
return errors.New("auth failure")
|
||||||
}
|
}
|
||||||
return nil
|
return nil
|
||||||
|
|
Loading…
Add table
Reference in a new issue