diff --git a/luci-app-passwall/Makefile b/luci-app-passwall/Makefile
index ef7e3bbca..7868fe21b 100644
--- a/luci-app-passwall/Makefile
+++ b/luci-app-passwall/Makefile
@@ -6,7 +6,7 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=luci-app-passwall
-PKG_VERSION:=4.75-3
+PKG_VERSION:=4.75-4
PKG_RELEASE:=
PKG_CONFIG_DEPENDS:= \
diff --git a/luci-app-passwall/luasrc/model/cbi/passwall/client/acl_config.lua b/luci-app-passwall/luasrc/model/cbi/passwall/client/acl_config.lua
index 45b909c70..55e21430c 100644
--- a/luci-app-passwall/luasrc/model/cbi/passwall/client/acl_config.lua
+++ b/luci-app-passwall/luasrc/model/cbi/passwall/client/acl_config.lua
@@ -141,17 +141,17 @@ sources.validate = function(self, value, t)
end
sources.write = dynamicList_write
-local TCP_NODE = uci:get(appname, "@global[0]", "tcp_node")
+--local TCP_NODE = uci:get(appname, "@global[0]", "tcp_node")
tcp_node = s:option(ListValue, "tcp_node", "" .. translate("TCP Node") .. "")
-tcp_node.default = "default"
+tcp_node.default = "nil"
tcp_node:value("nil", translate("Close"))
-tcp_node:value("default", translate("Use global config") .. "(" .. TCP_NODE .. ")")
+--tcp_node:value("default", translate("Use global config") .. "(" .. TCP_NODE .. ")")
-local UDP_NODE = uci:get(appname, "@global[0]", "udp_node")
+--local UDP_NODE = uci:get(appname, "@global[0]", "udp_node")
udp_node = s:option(ListValue, "udp_node", "" .. translate("UDP Node") .. "")
-udp_node.default = "default"
+udp_node.default = "nil"
udp_node:value("nil", translate("Close"))
-udp_node:value("default", translate("Use global config") .. "(" .. UDP_NODE .. ")")
+--udp_node:value("default", translate("Use global config") .. "(" .. UDP_NODE .. ")")
udp_node:value("tcp", translate("Same as the tcp node"))
for k, v in pairs(nodes_table) do
@@ -258,6 +258,9 @@ o:value("disable", translate("No Proxy"))
o:value("proxy", translate("Proxy"))
o:depends({ udp_node = "nil", ['!reverse'] = true })
+o = s:option(DummyValue, "", " ")
+o.template = appname .. "/global/proxy"
+
o = s:option(Flag, "filter_proxy_ipv6", translate("Filter Proxy Host IPv6"), translate("Experimental feature."))
o.default = "0"
o:depends({ tcp_node = "nil", ['!reverse'] = true })
@@ -388,8 +391,10 @@ o.description = translate("The default DNS used when not in the domain name rule
.. "
" .. translate("Remote DNS can avoid more DNS leaks, but some domestic domain names maybe to proxy!") .. ""
.. "" .. translate("Direct DNS Internet experience may be better, but DNS will be leaked!") .. ""
.. ""
+local _depends = {tcp_proxy_mode = "proxy"}
if api.is_finded("chinadns-ng") then
- o:depends("chinadns_ng", false)
+ _depends["chinadns_ng"] = false
end
+o:depends(_depends)
return m
diff --git a/luci-app-passwall/luasrc/model/cbi/passwall/client/global.lua b/luci-app-passwall/luasrc/model/cbi/passwall/client/global.lua
index 77dd44440..6be4aa438 100644
--- a/luci-app-passwall/luasrc/model/cbi/passwall/client/global.lua
+++ b/luci-app-passwall/luasrc/model/cbi/passwall/client/global.lua
@@ -458,6 +458,9 @@ localhost_udp_proxy_mode:value("disable", translate("No Proxy"))
localhost_udp_proxy_mode:value("proxy", translate("Proxy"))
localhost_udp_proxy_mode.default = "default"
+o = s:taboption("Proxy", DummyValue, "", " ")
+o.template = appname .. "/global/proxy"
+
tips = s:taboption("Proxy", DummyValue, "tips", " ")
tips.rawhtml = true
tips.cfgvalue = function(t, n)
diff --git a/luci-app-passwall/luasrc/view/passwall/global/proxy.htm b/luci-app-passwall/luasrc/view/passwall/global/proxy.htm
new file mode 100644
index 000000000..4e05f3336
--- /dev/null
+++ b/luci-app-passwall/luasrc/view/passwall/global/proxy.htm
@@ -0,0 +1,108 @@
+
+
+
+
+
+
diff --git a/luci-app-passwall/po/zh-cn/passwall.po b/luci-app-passwall/po/zh-cn/passwall.po
index 4bffef374..fe2be6c9a 100644
--- a/luci-app-passwall/po/zh-cn/passwall.po
+++ b/luci-app-passwall/po/zh-cn/passwall.po
@@ -277,9 +277,6 @@ msgstr "GFW列表"
msgid "Not China List"
msgstr "中国列表以外"
-msgid "Game Mode"
-msgstr "游戏模式"
-
msgid "China List"
msgstr "中国列表"
@@ -292,12 +289,12 @@ msgstr "路由器本机"
msgid "Same as the %s default proxy mode"
msgstr "与 %s 默认代理模式相同"
+msgid "Switch Mode"
+msgstr "切换模式"
+
msgid "Want different devices to use different proxy modes/ports/nodes? Please use access control."
msgstr "希望不同设备使用不同的代理模式/端口/节点?请使用访问控制。"
-msgid "China list or gfwlist cannot be used together with outside China list!"
-msgstr "中国列表不能和中国列表外或防火墙表一起使用!"
-
msgid "Operation"
msgstr "操作"
diff --git a/luci-app-passwall/root/usr/share/passwall/app.sh b/luci-app-passwall/root/usr/share/passwall/app.sh
index 779698838..0903738d4 100755
--- a/luci-app-passwall/root/usr/share/passwall/app.sh
+++ b/luci-app-passwall/root/usr/share/passwall/app.sh
@@ -799,17 +799,13 @@ run_redir() {
_args="${_args} udp_redir_port=${UDP_REDIR_PORT}"
config_file=$(echo $config_file | sed "s/TCP/TCP_UDP/g")
}
- local v2ray_dns_mode=$(config_t_get global v2ray_dns_mode tcp)
- [ "${DNS_MODE}" != "sing-box" ] && [ "${DNS_MODE}" != "udp" ] && {
- DNS_MODE="sing-box"
- v2ray_dns_mode="tcp"
- }
[ "${DNS_MODE}" = "sing-box" ] && {
resolve_dns=1
config_file=$(echo $config_file | sed "s/.json/_DNS.json/g")
_args="${_args} remote_dns_query_strategy=${DNS_QUERY_STRATEGY}"
FILTER_PROXY_IPV6=0
[ "${DNS_CACHE}" == "0" ] && _args="${_args} dns_cache=0"
+ local v2ray_dns_mode=$(config_t_get global v2ray_dns_mode tcp)
_args="${_args} remote_dns_protocol=${v2ray_dns_mode}"
_args="${_args} dns_listen_port=${dns_listen_port}"
local logout=""
@@ -854,11 +850,6 @@ run_redir() {
_args="${_args} udp_redir_port=${UDP_REDIR_PORT}"
config_file=$(echo $config_file | sed "s/TCP/TCP_UDP/g")
}
- local v2ray_dns_mode=$(config_t_get global v2ray_dns_mode tcp)
- [ "${DNS_MODE}" != "xray" ] && [ "${DNS_MODE}" != "udp" ] && {
- DNS_MODE="xray"
- v2ray_dns_mode="tcp"
- }
[ "${DNS_MODE}" = "xray" ] && {
resolve_dns=1
config_file=$(echo $config_file | sed "s/.json/_DNS.json/g")
@@ -869,6 +860,7 @@ run_redir() {
[ "${DNS_CACHE}" == "0" ] && _args="${_args} dns_cache=0"
_args="${_args} dns_listen_port=${dns_listen_port}"
_args="${_args} remote_dns_tcp_server=${REMOTE_DNS}"
+ local v2ray_dns_mode=$(config_t_get global v2ray_dns_mode tcp)
[ "$v2ray_dns_mode" = "tcp+doh" ] && {
remote_dns_doh=$(config_t_get global remote_dns_doh "https://1.1.1.1/dns-query")
_args="${_args} remote_dns_doh=${remote_dns_doh}"