docs: 客户端可配置分流设计+原型(并入 v2 作开发基线) #7

Closed
wangjia wants to merge 39 commits from design/configurable-proxy into feat/pay-v2-integration
Showing only changes of commit d4156b81e2 - Show all commits
+2 -9
View File
@@ -6,7 +6,6 @@ import (
"net" "net"
"os" "os"
"strconv" "strconv"
"strings"
) )
// WarpConfig 描述节点上「部分域名走 Cloudflare WARP 干净出口」的分流配置(#29)。 // WarpConfig 描述节点上「部分域名走 Cloudflare WARP 干净出口」的分流配置(#29)。
@@ -66,15 +65,9 @@ func (wc *WarpConfig) mtu() int {
} }
// cleanDomains 去空白/空项后返回域名清单(用于 domain_suffix)。 // cleanDomains 去空白/空项后返回域名清单(用于 domain_suffix)。
// 与 ACL 的目的地域名规范化共用 cleanHosts,避免两处逻辑漂移。
func (wc *WarpConfig) cleanDomains() []string { func (wc *WarpConfig) cleanDomains() []string {
out := make([]string, 0, len(wc.Domains)) return cleanHosts(wc.Domains)
for _, d := range wc.Domains {
d = strings.TrimSpace(strings.ToLower(d))
if d != "" {
out = append(out, d)
}
}
return out
} }
// endpointHostPort 拆 Endpoint 为 host + port(active() 已校验可拆)。 // endpointHostPort 拆 Endpoint 为 host + port(active() 已校验可拆)。