use correct realm
This commit is contained in:
parent
552e1e3ac1
commit
25e38814a2
|
@ -106,7 +106,7 @@ func (srv *server) ServeHTTP(w http.ResponseWriter, r *http.Request) {
|
|||
password := config.Get("HTTP_PASS")
|
||||
|
||||
if !ok || subtle.ConstantTimeCompare([]byte(user), []byte(username)) != 1 || subtle.ConstantTimeCompare([]byte(pass), []byte(password)) != 1 {
|
||||
w.Header().Set("WWW-Authenticate", `Basic realm="quicknote"`)
|
||||
w.Header().Set("WWW-Authenticate", `Basic realm="kls"`)
|
||||
w.WriteHeader(401)
|
||||
w.Write([]byte("Unauthorised.\n"))
|
||||
return
|
||||
|
|
Loading…
Reference in New Issue