luci-app-passwall: sync upstream

last commit: a5ea05fee3
This commit is contained in:
sbwml 2024-09-10 12:42:01 +08:00
parent b74b91aeb0
commit 606d4077c7
2 changed files with 20 additions and 1 deletions

View File

@ -371,6 +371,10 @@ local api = require "luci.passwall.api"
v_transport = "splithttp"; v_transport = "splithttp";
params += opt.query("host", dom_prefix + "splithttp_host"); params += opt.query("host", dom_prefix + "splithttp_host");
params += opt.query("path", dom_prefix + "splithttp_path"); params += opt.query("path", dom_prefix + "splithttp_path");
} else if (v_transport === "httpupgrade") {
v_transport = "httpupgrade";
params += opt.query("host", dom_prefix + "httpupgrade_host");
params += opt.query("path", dom_prefix + "httpupgrade_path");
} }
params += "&type=" + v_transport; params += "&type=" + v_transport;
@ -1149,6 +1153,9 @@ local api = require "luci.passwall.api"
} else if (queryParam.type === "splithttp") { } else if (queryParam.type === "splithttp") {
opt.set(dom_prefix + 'splithttp_host', queryParam.host || ""); opt.set(dom_prefix + 'splithttp_host', queryParam.host || "");
opt.set(dom_prefix + 'splithttp_path', queryParam.path || ""); opt.set(dom_prefix + 'splithttp_path', queryParam.path || "");
} else if (queryParam.type === "httpupgrade") {
opt.set(dom_prefix + 'httpupgrade_host', queryParam.host || "");
opt.set(dom_prefix + 'httpupgrade_path', queryParam.path || "");
} }
if (m.hash) { if (m.hash) {

View File

@ -492,6 +492,10 @@ local function processData(szType, content, add_mode, add_from)
result.splithttp_host = info.host result.splithttp_host = info.host
result.splithttp_path = info.path result.splithttp_path = info.path
end end
if info.net == 'httpupgrade' then
result.httpupgrade_host = info.host
result.httpupgrade_path = info.path
end
if not info.security then result.security = "auto" end if not info.security then result.security = "auto" end
if info.tls == "tls" or info.tls == "1" then if info.tls == "tls" or info.tls == "1" then
result.tls = "1" result.tls = "1"
@ -835,6 +839,10 @@ local function processData(szType, content, add_mode, add_from)
result.splithttp_host = params.host result.splithttp_host = params.host
result.splithttp_path = params.path result.splithttp_path = params.path
end end
if params.type == 'httpupgrade' then
result.httpupgrade_host = params.host
result.httpupgrade_path = params.path
end
result.encryption = params.encryption or "none" result.encryption = params.encryption or "none"
@ -968,6 +976,10 @@ local function processData(szType, content, add_mode, add_from)
result.splithttp_host = params.host result.splithttp_host = params.host
result.splithttp_path = params.path result.splithttp_path = params.path
end end
if params.type == 'httpupgrade' then
result.httpupgrade_host = params.host
result.httpupgrade_path = params.path
end
result.encryption = params.encryption or "none" result.encryption = params.encryption or "none"