From 23e3d49d74770edf492e919c720c0b2fd51ec56e Mon Sep 17 00:00:00 2001 From: Tianling Shen Date: Tue, 8 Nov 2022 14:20:33 +0800 Subject: [PATCH] luci-app-ssr-plus: allow custom fingerprints with XTLS Signed-off-by: Tianling Shen --- .../luasrc/model/cbi/shadowsocksr/client-config.lua | 1 + luci-app-ssr-plus/root/usr/share/shadowsocksr/gen_config.lua | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/luci-app-ssr-plus/luasrc/model/cbi/shadowsocksr/client-config.lua b/luci-app-ssr-plus/luasrc/model/cbi/shadowsocksr/client-config.lua index 691f60ee7..ab34d2684 100644 --- a/luci-app-ssr-plus/luasrc/model/cbi/shadowsocksr/client-config.lua +++ b/luci-app-ssr-plus/luasrc/model/cbi/shadowsocksr/client-config.lua @@ -661,6 +661,7 @@ if is_finded("xray") then o:value("safari", translate("safari")) o:value("randomized", translate("randomized")) o:depends({type = "v2ray", tls = true}) + o:depends({type = "v2ray", xtls = true}) o.default = "disable" end diff --git a/luci-app-ssr-plus/root/usr/share/shadowsocksr/gen_config.lua b/luci-app-ssr-plus/root/usr/share/shadowsocksr/gen_config.lua index eb0e6e369..25ed022aa 100755 --- a/luci-app-ssr-plus/root/usr/share/shadowsocksr/gen_config.lua +++ b/luci-app-ssr-plus/root/usr/share/shadowsocksr/gen_config.lua @@ -161,8 +161,9 @@ local Xray = { allowInsecure = (server.insecure == "1") and true or nil, serverName = server.tls_host } or nil, - xtlsSettings = (server.xtls == '1' and (server.insecure == "1" or server.tls_host)) and { + xtlsSettings = (server.xtls == '1' and (server.insecure == "1" or server.tls_host or server.fingerprint)) and { -- xtls + fingerprint = server.fingerprint, allowInsecure = (server.insecure == "1") and true or nil, serverName = server.tls_host, minVersion = "1.3"