Parcourir la source

luci-app-ssr-plus: allow custom fingerprints with XTLS

Signed-off-by: Tianling Shen <[email protected]>
Tianling Shen il y a 3 ans
Parent
commit
19ae664cd9

+ 1 - 0
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
 

+ 2 - 1
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"