Skip to content

Commit

Permalink
fix basic auth (#564)
Browse files Browse the repository at this point in the history
* fix basic auth

* better logic
  • Loading branch information
aspacca authored Jun 6, 2023
1 parent fc844ac commit 45e2654
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion server/handlers.go
Original file line number Diff line number Diff line change
Expand Up @@ -1326,7 +1326,7 @@ func ipFilterHandler(h http.Handler, ipFilterOptions *IPFilterOptions) http.Hand

func (s *Server) basicAuthHandler(h http.Handler) http.HandlerFunc {
return func(w http.ResponseWriter, r *http.Request) {
if s.authUser == "" || s.authPass == "" || s.authHtpasswd == "" {
if s.authUser == "" && s.authPass == "" && s.authHtpasswd == "" {
h.ServeHTTP(w, r)
return
}
Expand Down

0 comments on commit 45e2654

Please sign in to comment.