update 2022-08-13 23:40:54

This commit is contained in:
github-actions[bot]
2022-08-13 23:40:54 +08:00
parent 5a3feb469f
commit 39e1a44c8a
9 changed files with 70 additions and 74 deletions

View File

@@ -1,7 +1,7 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=aliyundrive-webdav
PKG_VERSION:=1.8.9
PKG_VERSION:=1.9.0
PKG_RELEASE:=$(AUTORELEASE)
PKG_LICENSE:=MIT

View File

@@ -17,3 +17,4 @@ config server
option tls_cert ''
option tls_key ''
option skip_upload_same_size '0'
option prefer_http_download '0'

View File

@@ -55,6 +55,13 @@ start_service() {
;;
*) ;;
esac
case "$(uci_get_by_type server prefer_http_download 0)" in
1|on|true|yes|enabled)
extra_options="$extra_options --prefer-http-download"
;;
*) ;;
esac
fi
if [[ ! -z "$tls_cert" && ! -z "$tls_key" ]]; then

View File

@@ -1,7 +1,7 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=luci-app-aliyundrive-webdav
PKG_VERSION:=1.8.9
PKG_VERSION:=1.9.0
PKG_RELEASE:=1
PKG_PO_VERSION:=$(PKG_VERSION)-$(PKG_RELEASE)

View File

@@ -40,6 +40,10 @@ read_buffer_size = e:option(Value, "read_buffer_size", translate("Read Buffer Si
read_buffer_size.default = "10485760"
read_buffer_size.datatype = "uinteger"
prefer_http_download = e:option(Flag, "prefer_http_download", translate("Prefer HTTP Download"))
prefer_http_download.description = translate("Prefer downloading files using HTTP instead of HTTPS protocol")
prefer_http_download.rmempty = false
upload_buffer_size = e:option(Value, "upload_buffer_size", translate("Upload Buffer Size"))
upload_buffer_size.default = "16777216"
upload_buffer_size.datatype = "uinteger"

View File

@@ -96,3 +96,9 @@ msgstr "跳过上传相同大小的文件"
msgid "Reduce the upload traffic by skipping uploading files with the same size"
msgstr "跳过上传相同大小的文件减少上传流量消耗,但可能会导致修改过的同样大小的文件不会被上传"
msgid "Prefer HTTP Download"
msgstr "使用 HTTP 下载"
msgid "Prefer downloading files using HTTP instead of HTTPS protocol"
msgstr "优先使用 HTTP 而不是 HTTPS 协议下载,低端设备上降低 CPU 占用"

View File

@@ -2,7 +2,7 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=luci-app-ssr-plus
PKG_VERSION:=186
PKG_RELEASE:=5
PKG_RELEASE:=6
PKG_CONFIG_DEPENDS:= \
CONFIG_PACKAGE_$(PKG_NAME)_INCLUDE_NONE_V2RAY \
@@ -29,8 +29,8 @@ LUCI_PKGARCH:=all
LUCI_DEPENDS:= \
@(PACKAGE_libustream-mbedtls||PACKAGE_libustream-openssl||PACKAGE_libustream-wolfssl) \
+coreutils +coreutils-base64 +dns2socks +dns2tcp +dnsmasq-full +ipset +kmod-ipt-nat \
+ip-full +iptables +iptables-mod-tproxy +lua +libuci-lua +microsocks +tcping \
+resolveip +shadowsocksr-libev-ssr-check +uclient-fetch \
+ip-full +iptables +iptables-mod-tproxy +lua +lua-neturl +libuci-lua +microsocks \
+tcping +resolveip +shadowsocksr-libev-ssr-check +uclient-fetch \
+PACKAGE_$(PKG_NAME)_INCLUDE_V2ray:curl \
+PACKAGE_$(PKG_NAME)_INCLUDE_V2ray:v2ray-core \
+PACKAGE_$(PKG_NAME)_INCLUDE_Xray:curl \

View File

@@ -173,7 +173,8 @@ local Xray = {
xtlsSettings = (server.xtls == '1' and (server.insecure == "1" or server.tls_host)) and {
-- xtls
allowInsecure = (server.insecure == "1") and true or nil,
serverName = server.tls_host
serverName = server.tls_host,
minVersion = "1.3"
} or nil,
tcpSettings = (server.transport == "tcp" and server.tcp_guise == "http") and {
-- tcp

View File

@@ -16,6 +16,7 @@ local tinsert = table.insert
local ssub, slen, schar, sbyte, sformat, sgsub = string.sub, string.len, string.char, string.byte, string.format, string.gsub
local jsonParse, jsonStringify = luci.jsonc.parse, luci.jsonc.stringify
local b64decode = nixio.bin.b64decode
local URL = require "url"
local cache = {}
local nodeResult = setmetatable({}, {__index = cache}) -- update result
local name = 'shadowsocksr'
@@ -349,75 +350,51 @@ local function processData(szType, content)
end
result.password = password
elseif szType == "vless" then
local idx_sp = 0
local alias = ""
if content:find("#") then
idx_sp = content:find("#")
alias = content:sub(idx_sp + 1, -1)
end
local info = content:sub(1, idx_sp - 1)
local hostInfo = split(info, "@")
local host = split(hostInfo[2], ":")
local uuid = hostInfo[1]
if host[2]:find("?") then
local query = split(host[2], "?")
local params = {}
for _, v in pairs(split(UrlDecode(query[2]), '&')) do
local t = split(v, '=')
params[t[1]] = t[2]
end
result.alias = UrlDecode(alias)
result.type = 'v2ray'
result.v2ray_protocol = 'vless'
result.server = host[1]
result.server_port = query[1]
result.vmess_id = uuid
local url = URL.parse("http://" .. content)
local params = url.query
result.alias = url.fragment and UrlDecode(url.fragment) or nil
result.type = "v2ray"
result.v2ray_protocol = "vless"
result.server = url.host
result.port = url.port
result.vmess_id = url.user
result.vless_encryption = params.encryption or "none"
result.transport = params.type and (params.type == 'http' and 'h2' or params.type) or "tcp"
result.transport = params.type or "tcp"
result.packet_encoding = packet_encoding
if not params.type or params.type == "tcp" then
if params.security == "xtls" then
result.xtls = "1"
result.tls = (params.security == "tls") and "1" or "0"
result.tls_host = params.sni
result.xtls = params.security == "xtls" and "1" or nil
result.vless_flow = params.flow
else
result.xtls = "0"
end
end
if params.type == 'ws' then
result.ws_host = params.host
result.ws_path = params.path or "/"
end
if params.type == 'http' then
result.h2_host = params.host
result.h2_path = params.path or "/"
end
if params.type == 'kcp' then
if result.transport == "ws" then
result.ws_host = (result.tls ~= "1") and (params.host and UrlDecode(params.host)) or nil
result.ws_path = params.path and UrlDecode(params.path) or "/"
elseif result.transport == "http" then
result.transport = "h2"
result.h2_host = params.host and UrlDecode(params.host) or nil
result.h2_path = params.path and UrlDecode(params.path) or nil
elseif result.transport == "kcp" then
result.kcp_guise = params.headerType or "none"
result.seed = params.seed
result.mtu = 1350
result.tti = 50
result.uplink_capacity = 5
result.downlink_capacity = 20
result.read_buffer_size = 2
result.write_buffer_size = 2
result.seed = params.seed
end
if params.type == 'quic' then
elseif result.transport == "quic" then
result.quic_guise = params.headerType or "none"
result.quic_key = params.key
result.quic_security = params.quicSecurity or "none"
end
if params.type == 'grpc' then
result.quic_key = params.key
elseif result.transport == "grpc" then
result.serviceName = params.serviceName
result.grpc_mode = params.mode or "gun"
elseif result.transport == "tcp" then
result.tcp_guise = params.headerType or "none"
if result.tcp_guise == "http" then
result.tcp_host = params.host and UrlDecode(params.host) or nil
result.tcp_path = params.path and UrlDecode(params.path) or nil
end
if params.security == "tls" then
result.tls = "1"
result.tls_host = params.sni
else
result.tls = "0"
end
else
result.server_port = host[2]
end
end
if not result.alias then