From 95f88a6f3c58c94afe9a33cddaff57dd07e402d3 Mon Sep 17 00:00:00 2001 From: yusing Date: Sat, 31 Jan 2026 18:51:15 +0800 Subject: [PATCH] fix(route): allow excluded routes to use localhost addresses Routes marked for exclusion should bypass normal validation checks, including the restriction on localhost/127.0.0.1 hostnames. --- internal/route/route.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/route/route.go b/internal/route/route.go index 8f1aa03c..3059483e 100644 --- a/internal/route/route.go +++ b/internal/route/route.go @@ -254,7 +254,7 @@ func (r *Route) validate() gperr.Error { } // return error if route is localhost: but route is not agent - if !r.IsAgent() { + if !r.IsAgent() && !r.ShouldExclude() { switch r.Host { case "localhost", "127.0.0.1": switch r.Port.Proxy {