From 28010b5f14a8b3ca922a16db9f70de71ced4514b Mon Sep 17 00:00:00 2001 From: action Date: Mon, 25 May 2026 16:15:17 +0800 Subject: [PATCH] update 2026-05-25 16:15:17 --- .../usr/share/passwall/clash_subconverter.lua | 18 ++++++++++++------ .../root/usr/share/passwall/subscribe.lua | 4 ++++ v2ray-geodata/Makefile | 4 ++-- 3 files changed, 18 insertions(+), 8 deletions(-) diff --git a/luci-app-passwall/root/usr/share/passwall/clash_subconverter.lua b/luci-app-passwall/root/usr/share/passwall/clash_subconverter.lua index 2dd8890f..e94afd64 100644 --- a/luci-app-passwall/root/usr/share/passwall/clash_subconverter.lua +++ b/luci-app-passwall/root/usr/share/passwall/clash_subconverter.lua @@ -258,6 +258,7 @@ local function encode_trojan(node) if o.tls.sni then table.insert(p, "sni=" .. urlencode(o.tls.sni)) end if o.tls.fp then table.insert(p, "fp=" .. urlencode(o.tls.fp)) end if o.tls.alpn then table.insert(p, "alpn=" .. urlencode(o.tls.alpn)) end + if o.tls.ech then table.insert(p, "ech=" .. urlencode(o.tls.ech)) end if o.tls.pcs then table.insert(p, "pcs=" .. urlencode(o.tls.pcs)) end table.insert(p, "allowInsecure=" .. (o.tls.insecure and "1" or "0")) @@ -294,6 +295,7 @@ local function encode_vmess(node) sni = o.tls.sni, alpn = o.tls.alpn, fp = o.tls.fp, + ech = o.tls.ech, pcs = o.tls.pcs, insecure = o.tls.insecure and "1" or "0", tfo = node.tfo and "1" or "0" @@ -425,7 +427,6 @@ local function encode_tuic(node) if node["disable-sni"] then table.insert(p, "disable_sni=1") end if node["skip-cert-verify"] then table.insert(p, "allowInsecure=1") end if node["udp-relay-mode"] then table.insert(p, "udp_relay_mode=" .. node["udp-relay-mode"]) end - if #p > 0 then link = link .. "?" .. table.concat(p, "&") @@ -436,14 +437,19 @@ end -- AnyTLS local function encode_anytls(node) + local o = build_common(node) + local link = "anytls://" .. (node.password or "") .. "@" .. host_format(node.server) .. ":" .. node.port local p = {} - if node.sni then table.insert(p, "sni=" .. urlencode(node.sni)) end - if node["skip-cert-verify"] then table.insert(p, "allowInsecure=1") end - - if node.alpn then - table.insert(p, "alpn=" .. urlencode(build_alpn(node.alpn))) + if o.tls.sni then table.insert(p, "sni=" .. urlencode(o.tls.sni)) end + if o.tls.alpn then table.insert(p, "alpn=" .. urlencode(o.tls.alpn)) end + if o.tls.fp then table.insert(p, "fp=" .. urlencode(o.tls.fp)) end + if o.tls.ech then table.insert(p, "ech=" .. urlencode(o.tls.ech)) end + if o.tls.pcs then + table.insert(p, "allowInsecure=1") + else + table.insert(p, "allowInsecure=" .. (o.tls.insecure and "1" or "0")) end if #p > 0 then diff --git a/luci-app-passwall/root/usr/share/passwall/subscribe.lua b/luci-app-passwall/root/usr/share/passwall/subscribe.lua index b3bed70f..ce5757c4 100755 --- a/luci-app-passwall/root/usr/share/passwall/subscribe.lua +++ b/luci-app-passwall/root/usr/share/passwall/subscribe.lua @@ -1547,6 +1547,10 @@ local function processData(szType, content, add_mode, group, sub_cfg) result.reality_publicKey = params.pbk or nil result.reality_shortId = params.sid or nil end + if params.ech and params.ech ~= "" then + result.ech = "1" + result.ech_config = params.ech + end end result.port = port local insecure = params.allowinsecure or params.insecure diff --git a/v2ray-geodata/Makefile b/v2ray-geodata/Makefile index 481202f7..b1cbe54f 100644 --- a/v2ray-geodata/Makefile +++ b/v2ray-geodata/Makefile @@ -30,13 +30,13 @@ define Download/geosite HASH:=1c039aacd6346523f7a316d63318c62d4333864f7a88519e445777005cf65ef3 endef -GEOSITE_IRAN_VER:=202605180152 +GEOSITE_IRAN_VER:=202605250156 GEOSITE_IRAN_FILE:=iran.dat.$(GEOSITE_IRAN_VER) define Download/geosite-ir URL:=https://github.com/bootmortis/iran-hosted-domains/releases/download/$(GEOSITE_IRAN_VER)/ URL_FILE:=iran.dat FILE:=$(GEOSITE_IRAN_FILE) - HASH:=4dbd8da72b1a785cde54611c6867619b3e6fb064050fb2903d29345900a4dd54 + HASH:=2ae051203f836c859169a46c81b2ce177b608c2a95897c47db5e3cce446cdea9 endef define Package/v2ray-geodata/template