add trace logs

This commit is contained in:
pascal
2026-02-04 22:26:29 +01:00
parent d09c69f303
commit 3af16cf333
2 changed files with 8 additions and 1 deletions

View File

@@ -9,9 +9,11 @@ import (
"sync"
"time"
"github.com/netbirdio/netbird/proxy/auth"
log "github.com/sirupsen/logrus"
"google.golang.org/grpc"
"github.com/netbirdio/netbird/proxy/auth"
"github.com/netbirdio/netbird/proxy/web"
"github.com/netbirdio/netbird/shared/management/proto"
)
@@ -67,6 +69,8 @@ func (mw *Middleware) Protect(next http.Handler) http.Handler {
config, exists := mw.domains[host]
mw.domainsMux.RUnlock()
log.Tracef("checking authentication for host: %s, exists: %t", host, exists)
// Domains that are not configured here or have no authentication schemes applied should simply pass through.
if !exists || len(config.Schemes) == 0 {
next.ServeHTTP(w, r)