🎈 Sync 2026-10-28 12:40:08

This commit is contained in:
github-actions[bot] committed 2026-10-28 12:40:08 +08:00
1 parent d42296f292
commit cfb89528fa
20 files changed
+1459 -766

No files matched your search

+1 -1
View File
@@ -7,7 +7,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=luci-app-passwall2
PKG_VERSION:=26.10.20
PKG_RELEASE:=152
PKG_RELEASE:=153
PKG_PO_VERSION:=$(PKG_VERSION)
PKG_CONFIG_DEPENDS:= \
@@ -248,12 +248,12 @@ function socks_autoswitch_add_node()
uci_set(id, "enable_autoswitch", "1")
local new_list = uci_get(id, "autoswitch_backup_node") or {}
for i = #new_list, 1, -1 do
if (uci_get(new_list[i], "remarks") or ""):find(key) then
if (uci_get(new_list[i], "remarks") or ""):find(key, 1, true) then
table.remove(new_list, i)
end
end
for k, e in ipairs(api.get_valid_nodes()) do
if e.node_type == "normal" and e["remark"]:find(key) then
if e.node_type == "normal" and e["remark"]:find(key, 1, true) then
table.insert(new_list, e.id)
end
end
@@ -270,7 +270,7 @@ function socks_autoswitch_remove_node()
uci_set(id, "enable_autoswitch", "1")
local new_list = uci_get(id, "autoswitch_backup_node") or {}
for i = #new_list, 1, -1 do
if (uci_get(new_list[i], "remarks") or ""):find(key) then
if (uci_get(new_list[i], "remarks") or ""):find(key, 1, true) then
table.remove(new_list, i)
end
end
+6 -5
View File
@@ -1518,11 +1518,6 @@ function to_move(app_name,file)
}
end
local flag = sys.call('busybox pgrep -af "passwall2/.*'.. app_name ..'" >/dev/null')
if flag == 0 then
sys.call("/etc/init.d/passwall2 stop")
end
local old_app_size = 0
if fs.access(app_path) then
old_app_size = get_file_space(app_path)
@@ -1538,6 +1533,12 @@ function to_move(app_name,file)
end
end
-- Complete preflight before stopping an otherwise working proxy.
local flag = sys.call('busybox pgrep -af "passwall2/.*'.. app_name ..'" >/dev/null')
if flag == 0 then
sys.call("/etc/init.d/passwall2 stop")
end
result = exec("/bin/mv", { "-f", bin_path, app_path }, nil, command_timeout) == 0
sys.call(cmd_rm_tmp)
@@ -402,7 +402,9 @@ function gen_outbound(flag, node, tag, proxy_table)
end)(node.hysteria2_keep_alive_period),
disablePathMTUDiscovery = node.hysteria2_disable_mtu_discovery == "1",
initStreamReceiveWindow = tonumber(node.hysteria2_stream_recv_win) and tonumber(node.hysteria2_stream_recv_win)*1048576 or nil,
maxStreamReceiveWindow = tonumber(node.hysteria2_stream_recv_win) and tonumber(node.hysteria2_stream_recv_win)*1048576 or nil,
initConnectionReceiveWindow = tonumber(node.hysteria2_conn_recv_win) and tonumber(node.hysteria2_conn_recv_win)*1048576 or nil,
maxConnectionReceiveWindow = tonumber(node.hysteria2_conn_recv_win) and tonumber(node.hysteria2_conn_recv_win)*1048576 or nil,
}
end
if fragment and fragment_table and ({raw=1, ws=1, httpupgrade=1, grpc=1, xhttp=1})[TP] then
@@ -9,13 +9,13 @@ local api = map.api
function add_node_by_key() {
var key = prompt("<%:Please enter the node keyword, pay attention to distinguish between spaces, uppercase and lowercase.%>", "");
if (key) {
window.location.href = '<%=api.url("socks_autoswitch_add_node")%>' + "?id=" + socks_id + "&key=" + key;
window.location.href = '<%=api.url("socks_autoswitch_add_node")%>' + "?id=" + encodeURIComponent(socks_id) + "&key=" + encodeURIComponent(key);
}
}
function remove_node_by_key() {
var key = prompt("<%:Please enter the node keyword, pay attention to distinguish between spaces, uppercase and lowercase.%>", "");
if (key) {
window.location.href = '<%=api.url("socks_autoswitch_remove_node")%>' + "?id=" + socks_id + "&key=" + key;
window.location.href = '<%=api.url("socks_autoswitch_remove_node")%>' + "?id=" + encodeURIComponent(socks_id) + "&key=" + encodeURIComponent(key);
}
}
//]]>