From 83b2d886ece3786170d21e8640e1d9da6e65422e Mon Sep 17 00:00:00 2001 From: kenzok8 Date: Tue, 30 Apr 2024 20:29:53 +0800 Subject: [PATCH] update 2024-04-30 20:29:53 --- .../luasrc/model/cbi/passwall/client/other.lua | 10 +++++----- luci-app-passwall/luasrc/passwall/util_xray.lua | 4 ++-- luci-app-passwall/po/zh-cn/passwall.po | 6 +++--- nps/Makefile | 8 ++++---- 4 files changed, 14 insertions(+), 14 deletions(-) diff --git a/luci-app-passwall/luasrc/model/cbi/passwall/client/other.lua b/luci-app-passwall/luasrc/model/cbi/passwall/client/other.lua index 2e2800c9b..4dd6967e0 100644 --- a/luci-app-passwall/luasrc/model/cbi/passwall/client/other.lua +++ b/luci-app-passwall/luasrc/model/cbi/passwall/client/other.lua @@ -158,7 +158,7 @@ if has_xray then o = s_xray:option(Flag, "fragment", translate("Fragment"), translate("TCP fragments, which can deceive the censorship system in some cases, such as bypassing SNI blacklists.")) o.default = 0 - + o = s_xray:option(ListValue, "fragment_packets", translate("Fragment Packets"), translate("\"1-3\" is for segmentation at TCP layer, applying to the beginning 1 to 3 data writes by the client. \"tlshello\" is for TLS client hello packet fragmentation.")) o.default = "tlshello" o:value("tlshello", "tlshello") @@ -166,16 +166,16 @@ if has_xray then o:value("1-3", "1-3") o:value("1-5", "1-5") o:depends("fragment", true) - + o = s_xray:option(Value, "fragment_length", translate("Fragment Length"), translate("Fragmented packet length (byte)")) o.default = "100-200" o:depends("fragment", true) - + o = s_xray:option(Value, "fragment_interval", translate("Fragment Interval"), translate("Fragmentation interval (ms)")) o.default = "10-20" o:depends("fragment", true) - - o = s_xray:option(Flag, "sniffing", translate("Sniffing"), translate("When using the shunt, must be enabled, otherwise the shunt will invalid.")) + + o = s_xray:option(Flag, "sniffing", translate("Sniffing"), translate("When using the shunt, this option will be forced to be enabled.")) o.default = 1 o.rmempty = false diff --git a/luci-app-passwall/luasrc/passwall/util_xray.lua b/luci-app-passwall/luasrc/passwall/util_xray.lua index c76ef0b63..0043db806 100644 --- a/luci-app-passwall/luasrc/passwall/util_xray.lua +++ b/luci-app-passwall/luasrc/passwall/util_xray.lua @@ -616,10 +616,10 @@ function gen_config(var) settings = {network = "tcp,udp", followRedirect = true}, streamSettings = {sockopt = {tproxy = "tproxy"}}, sniffing = { - enabled = xray_settings.sniffing == "1" and true or false, + enabled = xray_settings.sniffing == "1" or node.protocol == "_shunt",, destOverride = {"http", "tls", "quic"}, metadataOnly = false, - routeOnly = (xray_settings.sniffing == "1" and xray_settings.route_only == "1") and true or nil, + routeOnly = (xray_settings.sniffing == "1" and xray_settings.route_only == "1") or (xray_settings.sniffing == "0" and node.protocol == "_shunt"), domainsExcluded = (xray_settings.sniffing == "1" and xray_settings.route_only == "0") and get_domain_excluded() or nil } } diff --git a/luci-app-passwall/po/zh-cn/passwall.po b/luci-app-passwall/po/zh-cn/passwall.po index 4c09f0d13..b201e4526 100644 --- a/luci-app-passwall/po/zh-cn/passwall.po +++ b/luci-app-passwall/po/zh-cn/passwall.po @@ -691,11 +691,11 @@ msgstr "劫持ICMPv6 (IPv6 PING)" msgid "Sniffing" msgstr "流量嗅探" -msgid "When using the shunt, must be enabled, otherwise the shunt will invalid." -msgstr "使用分流时,必须启用,否则分流将无效。" +msgid "When using the shunt, this option will be forced to be enabled." +msgstr "使用分流时,将强制启用此选项。" msgid "Sniffing Route Only" -msgstr "流量嗅探只供路由使用" +msgstr "流量嗅探仅供路由使用" msgid "TCP Proxy Way" msgstr "TCP 代理方式" diff --git a/nps/Makefile b/nps/Makefile index b1e82e80f..78c8d63c5 100644 --- a/nps/Makefile +++ b/nps/Makefile @@ -5,12 +5,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=nps -PKG_VERSION:=0.26.10 -PKG_RELEASE:=$(AUTORELEASE) +PKG_VERSION:=0.26.18 +PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz -PKG_SOURCE_URL:=https://codeload.github.com/ehang-io/nps/tar.gz/v$(PKG_VERSION)? -PKG_HASH:=1b2fe9d251f55105d65027a1cee464f65d2f6ab3bd4a20e4655e5135db68aee7 +PKG_SOURCE_URL:=https://codeload.github.com/yisier/nps/tar.gz/v$(PKG_VERSION)? +PKG_HASH:=29da044262071a1fa53ce7169c6427ee4f12fc0ada60ef7fb52fabfd165afe91 PKG_LICENSE:=Apache-2.0 PKG_LICENSE_FILE:=LICENSE