From 00cceba89063dab6ab8adbb2ccc97caefc23917c Mon Sep 17 00:00:00 2001 From: Anya Lin Date: Sat, 10 May 2025 13:12:45 +0800 Subject: [PATCH 1/3] docs: update config.yaml follow 7e7016b (#2022) --- docs/config.yaml | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/docs/config.yaml b/docs/config.yaml index af6e3a6161..999bd35f0a 100644 --- a/docs/config.yaml +++ b/docs/config.yaml @@ -906,6 +906,12 @@ proxies: # socks5 # dns 出站会将请求劫持到内部 dns 模块,所有请求均在内部处理 - name: "dns-out" type: dns + + # 配置指定 interface-name 和 fwmark 的 DIRECT + - name: en1-direct + type: direct + interface-name: en1 + routing-mark: 6667 proxy-groups: # 代理链,目前 relay 可以支持 udp 的只有 vmess/vless/trojan/ss/ssr/tuic # wireguard 目前不支持在 relay 中使用,请使用 proxy 中的 dialer-proxy 配置项 @@ -962,14 +968,6 @@ proxy-groups: - vmess1 - auto - # 配置指定 interface-name 和 fwmark 的 DIRECT - - name: en1 - type: select - interface-name: en1 - routing-mark: 6667 - proxies: - - DIRECT - - name: UseProvider type: select filter: "HK|TW" # 正则表达式,过滤 provider1 中节点名包含 HK 或 TW From d22a893060c0d224f2970e38e4b932e7d93189ad Mon Sep 17 00:00:00 2001 From: wwqgtxx Date: Sun, 11 May 2025 11:44:12 +0800 Subject: [PATCH 2/3] fix: hysteria server port hopping compatibility issues --- go.mod | 4 ++-- go.sum | 8 ++++---- listener/tuic/server.go | 1 + 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/go.mod b/go.mod index 0f06ecd21d..5878c628c6 100644 --- a/go.mod +++ b/go.mod @@ -23,11 +23,11 @@ require ( github.com/metacubex/chacha v0.1.2 github.com/metacubex/fswatch v0.1.1 github.com/metacubex/gopacket v1.1.20-0.20230608035415-7e2f98a3e759 - github.com/metacubex/quic-go v0.51.1-0.20250423035655-e3948b36ce14 + github.com/metacubex/quic-go v0.51.1-0.20250511032541-4e34341cf18b github.com/metacubex/randv2 v0.2.0 github.com/metacubex/sing v0.5.3-0.20250504031621-1f99e54c15b7 github.com/metacubex/sing-mux v0.3.2 - github.com/metacubex/sing-quic v0.0.0-20250504030450-1e678cb3d50b + github.com/metacubex/sing-quic v0.0.0-20250511034158-b46e0e3e81b2 github.com/metacubex/sing-shadowsocks v0.2.9 github.com/metacubex/sing-shadowsocks2 v0.2.3 github.com/metacubex/sing-shadowtls v0.0.0-20250503063515-5d9f966d17a2 diff --git a/go.sum b/go.sum index 8fe9af8986..3978d3a77a 100644 --- a/go.sum +++ b/go.sum @@ -111,8 +111,8 @@ github.com/metacubex/gvisor v0.0.0-20250324165734-5857f47bd43b h1:RUh4OdVPz/jDrM github.com/metacubex/gvisor v0.0.0-20250324165734-5857f47bd43b/go.mod h1:8LpS0IJW1VmWzUm3ylb0e2SK5QDm5lO/2qwWLZgRpBU= github.com/metacubex/nftables v0.0.0-20250503052935-30a69ab87793 h1:1Qpuy+sU3DmyX9HwI+CrBT/oLNJngvBorR2RbajJcqo= github.com/metacubex/nftables v0.0.0-20250503052935-30a69ab87793/go.mod h1:RjRNb4G52yAgfR+Oe/kp9G4PJJ97Fnj89eY1BFO3YyA= -github.com/metacubex/quic-go v0.51.1-0.20250423035655-e3948b36ce14 h1:vhB4KEgiN89xXtLlyYWczu3AxgN2T1lp0kIDYT4Faag= -github.com/metacubex/quic-go v0.51.1-0.20250423035655-e3948b36ce14/go.mod h1:9R1NOzCgTcWsdWvOMlmtMuF0uKzuOpsfvEf7U3I8zM0= +github.com/metacubex/quic-go v0.51.1-0.20250511032541-4e34341cf18b h1:8oDU32eJ+RRhl1FodGgPfxQxtoBAiD9D40XG2XtU/SE= +github.com/metacubex/quic-go v0.51.1-0.20250511032541-4e34341cf18b/go.mod h1:9R1NOzCgTcWsdWvOMlmtMuF0uKzuOpsfvEf7U3I8zM0= github.com/metacubex/randv2 v0.2.0 h1:uP38uBvV2SxYfLj53kuvAjbND4RUDfFJjwr4UigMiLs= github.com/metacubex/randv2 v0.2.0/go.mod h1:kFi2SzrQ5WuneuoLLCMkABtiBu6VRrMrWFqSPyj2cxY= github.com/metacubex/sing v0.5.2/go.mod h1:ypf0mjwlZm0sKdQSY+yQvmsbWa0hNPtkeqyRMGgoN+w= @@ -120,8 +120,8 @@ github.com/metacubex/sing v0.5.3-0.20250504031621-1f99e54c15b7 h1:m4nSxvw46JEgxM github.com/metacubex/sing v0.5.3-0.20250504031621-1f99e54c15b7/go.mod h1:ypf0mjwlZm0sKdQSY+yQvmsbWa0hNPtkeqyRMGgoN+w= github.com/metacubex/sing-mux v0.3.2 h1:nJv52pyRivHcaZJKk2JgxpaVvj1GAXG81scSa9N7ncw= github.com/metacubex/sing-mux v0.3.2/go.mod h1:3rt1soewn0O6j89GCLmwAQFsq257u0jf2zQSPhTL3Bw= -github.com/metacubex/sing-quic v0.0.0-20250504030450-1e678cb3d50b h1:JKx0yY/eXU7U5tHiAxANytFtkfEjzOte19qLlc+pFeY= -github.com/metacubex/sing-quic v0.0.0-20250504030450-1e678cb3d50b/go.mod h1:mqtr9bgM9eLvLKQqiLOi5I6AJHkvqAw2a61ABZcLuoE= +github.com/metacubex/sing-quic v0.0.0-20250511034158-b46e0e3e81b2 h1:wfmYgtECbEYo1slMtyo+2kMqscYYDSjU/TVgS3018F4= +github.com/metacubex/sing-quic v0.0.0-20250511034158-b46e0e3e81b2/go.mod h1:P1kd57U6XXmXv9PbwWdznUGT0k9bKgFJXF0fEORbIlk= github.com/metacubex/sing-shadowsocks v0.2.9 h1:2e++13WNN7EGjGtvrGLUzW1xrCdQbW2gIFpgw5GEw00= github.com/metacubex/sing-shadowsocks v0.2.9/go.mod h1:CJSEGO4FWQAWe+ZiLZxCweGdjRR60A61SIoVjdjQeBA= github.com/metacubex/sing-shadowsocks2 v0.2.3 h1:v3rNS/5Ywh0NIZ6VU/NmdERQIN5RePzyxCFeQsU4Cx0= diff --git a/listener/tuic/server.go b/listener/tuic/server.go index 75b39a5bf8..7bc63a737b 100644 --- a/listener/tuic/server.go +++ b/listener/tuic/server.go @@ -75,6 +75,7 @@ func New(config LC.TuicServer, tunnel C.Tunnel, additions ...inbound.Addition) ( MaxIncomingUniStreams: ServerMaxIncomingStreams, EnableDatagrams: true, Allow0RTT: true, + DisablePathManager: true, // for port hopping } quicConfig.InitialStreamReceiveWindow = tuic.DefaultStreamReceiveWindow / 10 quicConfig.MaxStreamReceiveWindow = tuic.DefaultStreamReceiveWindow From a4fcd3af07e3fe253bf3e93b35aba83d55f621e4 Mon Sep 17 00:00:00 2001 From: wwqgtxx Date: Mon, 12 May 2025 09:56:08 +0800 Subject: [PATCH 3/3] chore: rollback incompatible changes to updateConfigs api --- hub/route/configs.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hub/route/configs.go b/hub/route/configs.go index 56a9a53d6a..c43d3ef97b 100644 --- a/hub/route/configs.go +++ b/hub/route/configs.go @@ -373,9 +373,9 @@ func updateConfigs(w http.ResponseWriter, r *http.Request) { } else { if req.Path == "" { req.Path = C.Path.Config() - } else if !filepath.IsLocal(req.Path) { + } else if !filepath.IsAbs(req.Path) { render.Status(r, http.StatusBadRequest) - render.JSON(w, r, newError("path is not a valid absolute path")) + render.JSON(w, r, newError("path is not a absolute path")) return }