mirror of
https://github.com/hanwckf/immortalwrt-mt798x.git
synced 2025-01-10 11:09:57 +08:00
luci-app-passwall: bump to 3.9-39
This commit is contained in:
parent
dc9d40d98f
commit
d075409083
@ -7,8 +7,8 @@ include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=luci-app-passwall
|
||||
PKG_VERSION:=3.9
|
||||
PKG_RELEASE:=38
|
||||
PKG_DATE:=20200817
|
||||
PKG_RELEASE:=39
|
||||
PKG_DATE:=20200819
|
||||
|
||||
PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
|
||||
|
||||
|
@ -18,23 +18,26 @@ function index()
|
||||
if nixio.fs.access("/etc/config/passwall_show") then
|
||||
entry({"admin", "services", appname}, alias("admin", "services", appname, "settings"), _("Pass Wall"), 1).dependent = true
|
||||
end
|
||||
entry({"admin", "services", appname, "settings"}, cbi("passwall/global"), _("Basic Settings"), 1).dependent = true
|
||||
entry({"admin", "services", appname, "node_list"}, cbi("passwall/node_list"), _("Node List"), 2).dependent = true
|
||||
entry({"admin", "services", appname, "auto_switch"}, cbi("passwall/auto_switch"), _("Auto Switch"), 3).leaf = true
|
||||
entry({"admin", "services", appname, "other"}, cbi("passwall/other", {autoapply = true}), _("Other Settings"), 92).leaf = true
|
||||
--[[ Client ]]
|
||||
entry({"admin", "services", appname, "settings"}, cbi(appname .. "/client/global"), _("Basic Settings"), 1).dependent = true
|
||||
entry({"admin", "services", appname, "node_list"}, cbi(appname .. "/client/node_list"), _("Node List"), 2).dependent = true
|
||||
entry({"admin", "services", appname, "auto_switch"}, cbi(appname .. "/client/auto_switch"), _("Auto Switch"), 3).leaf = true
|
||||
entry({"admin", "services", appname, "other"}, cbi(appname .. "/client/other", {autoapply = true}), _("Other Settings"), 92).leaf = true
|
||||
if nixio.fs.access("/usr/sbin/haproxy") then
|
||||
entry({"admin", "services", appname, "haproxy"}, cbi("passwall/haproxy"), _("Load Balancing"), 93).leaf = true
|
||||
entry({"admin", "services", appname, "haproxy"}, cbi(appname .. "/client/haproxy"), _("Load Balancing"), 93).leaf = true
|
||||
end
|
||||
entry({"admin", "services", appname, "node_subscribe"}, cbi("passwall/node_subscribe"), _("Node Subscribe"), 94).dependent = true
|
||||
entry({"admin", "services", appname, "app_update"}, cbi("passwall/app_update"), _("App Update"), 95).leaf = true
|
||||
entry({"admin", "services", appname, "rule"}, cbi("passwall/rule"), _("Rule Manage"), 96).leaf = true
|
||||
entry({"admin", "services", appname, "rule_list"}, cbi("passwall/rule_list"), _("Rule List Manage"), 97).leaf = true
|
||||
entry({"admin", "services", appname, "node_config"}, cbi("passwall/node_config")).leaf = true
|
||||
entry({"admin", "services", appname, "shunt_rules"}, cbi("passwall/shunt_rules")).leaf = true
|
||||
entry({"admin", "services", appname, "acl"}, cbi("passwall/acl"), _("Access control"), 98).leaf = true
|
||||
entry({"admin", "services", appname, "server"}, cbi("passwall/server/index"), _("Server-Side"), 99).leaf = true
|
||||
entry({"admin", "services", appname, "log"}, form("passwall/log"), _("Watch Logs"), 999).leaf = true
|
||||
entry({"admin", "services", appname, "server_user"}, cbi("passwall/server/user")).leaf = true
|
||||
entry({"admin", "services", appname, "node_subscribe"}, cbi(appname .. "/client/node_subscribe"), _("Node Subscribe"), 94).dependent = true
|
||||
entry({"admin", "services", appname, "app_update"}, cbi(appname .. "/client/app_update"), _("App Update"), 95).leaf = true
|
||||
entry({"admin", "services", appname, "rule"}, cbi(appname .. "/client/rule"), _("Rule Manage"), 96).leaf = true
|
||||
entry({"admin", "services", appname, "rule_list"}, cbi(appname .. "/client/rule_list"), _("Rule List Manage"), 97).leaf = true
|
||||
entry({"admin", "services", appname, "node_config"}, cbi(appname .. "/client/node_config")).leaf = true
|
||||
entry({"admin", "services", appname, "shunt_rules"}, cbi(appname .. "/client/shunt_rules")).leaf = true
|
||||
entry({"admin", "services", appname, "acl"}, cbi(appname .. "/client/acl"), _("Access control"), 98).leaf = true
|
||||
entry({"admin", "services", appname, "log"}, form(appname .. "/client/log"), _("Watch Logs"), 999).leaf = true
|
||||
|
||||
--[[ Server ]]
|
||||
entry({"admin", "services", appname, "server"}, cbi(appname .. "/server/index"), _("Server-Side"), 99).leaf = true
|
||||
entry({"admin", "services", appname, "server_user"}, cbi(appname .. "/server/user")).leaf = true
|
||||
|
||||
--[[ API ]]
|
||||
entry({"admin", "services", appname, "server_user_status"}, call("server_user_status")).leaf = true
|
||||
@ -56,8 +59,6 @@ function index()
|
||||
entry({"admin", "services", appname, "clear_all_nodes"}, call("clear_all_nodes")).leaf = true
|
||||
entry({"admin", "services", appname, "delete_select_nodes"}, call("delete_select_nodes")).leaf = true
|
||||
entry({"admin", "services", appname, "update_rules"}, call("update_rules")).leaf = true
|
||||
entry({"admin", "services", appname, "luci_check"}, call("luci_check")).leaf = true
|
||||
entry({"admin", "services", appname, "luci_update"}, call("luci_update")).leaf = true
|
||||
entry({"admin", "services", appname, "kcptun_check"}, call("kcptun_check")).leaf = true
|
||||
entry({"admin", "services", appname, "kcptun_update"}, call("kcptun_update")).leaf = true
|
||||
entry({"admin", "services", appname, "brook_check"}, call("brook_check")).leaf = true
|
||||
@ -169,7 +170,7 @@ function connect_status()
|
||||
local e = {}
|
||||
e.use_time = ""
|
||||
local url = luci.http.formvalue("url")
|
||||
local result = luci.sys.exec('curl --connect-timeout 5 -o /dev/null -I -skL -w "%{http_code}:%{time_starttransfer}" ' .. url)
|
||||
local result = luci.sys.exec('curl --connect-timeout 3 -o /dev/null -I -skL -w "%{http_code}:%{time_starttransfer}" ' .. url)
|
||||
local code = tonumber(luci.sys.exec("echo -n '" .. result .. "' | awk -F ':' '{print $1}'") or "0")
|
||||
if code ~= 0 then
|
||||
local use_time = luci.sys.exec("echo -n '" .. result .. "' | awk -F ':' '{print $2}'")
|
||||
|
@ -0,0 +1,43 @@
|
||||
local d = require "luci.dispatcher"
|
||||
local appname = "passwall"
|
||||
|
||||
m = Map(appname, "V2ray" .. translate("Shunt") .. translate("Rule"))
|
||||
m.redirect = d.build_url("admin", "services", appname)
|
||||
|
||||
s = m:section(NamedSection, arg[1], "shunt_rules", "")
|
||||
s.addremove = false
|
||||
s.dynamic = false
|
||||
|
||||
remarks = s:option(Value, "remarks", translate("Remarks"))
|
||||
remarks.default = arg[1]
|
||||
remarks.rmempty = false
|
||||
|
||||
domain_list = s:option(TextValue, "domain_list", translate("Domain"))
|
||||
domain_list.rows = 15
|
||||
domain_list.wrap = "off"
|
||||
domain_list.validate = function(self, value)
|
||||
local hosts= {}
|
||||
string.gsub(value, '[^' .. "\r\n" .. ']+', function(w) table.insert(hosts, w) end)
|
||||
for index, host in ipairs(hosts) do
|
||||
if not datatypes.hostname(host) then
|
||||
return nil, host .. " " .. translate("Not valid domain name, please re-enter!")
|
||||
end
|
||||
end
|
||||
return value
|
||||
end
|
||||
|
||||
ip_list = s:option(TextValue, "ip_list", "IP")
|
||||
ip_list.rows = 15
|
||||
ip_list.wrap = "off"
|
||||
ip_list.validate = function(self, value)
|
||||
local ipmasks= {}
|
||||
string.gsub(value, '[^' .. "\r\n" .. ']+', function(w) table.insert(ipmasks, w) end)
|
||||
for index, ipmask in ipairs(ipmasks) do
|
||||
if not datatypes.ipmask4(ipmask) then
|
||||
return nil, ipmask .. " " .. translate("Not valid IP format, please re-enter!")
|
||||
end
|
||||
end
|
||||
return value
|
||||
end
|
||||
|
||||
return m
|
@ -1,21 +0,0 @@
|
||||
local d = require "luci.dispatcher"
|
||||
local appname = "passwall"
|
||||
|
||||
m = Map(appname, "V2ray" .. translate("Shunt") .. translate("Rule"))
|
||||
m.redirect = d.build_url("admin", "services", appname)
|
||||
|
||||
s = m:section(NamedSection, arg[1], "shunt_rules", "")
|
||||
s.addremove = false
|
||||
s.dynamic = false
|
||||
|
||||
remarks = s:option(Value, "remarks", translate("Remarks"))
|
||||
remarks.default = arg[1]
|
||||
remarks.rmempty = false
|
||||
|
||||
domain_list = s:option(TextValue, "domain_list", translate("Domain"))
|
||||
domain_list.rows = 15
|
||||
|
||||
ip_list = s:option(TextValue, "ip_list", "IP")
|
||||
ip_list.rows = 15
|
||||
|
||||
return m
|
@ -171,7 +171,7 @@ https://github.com/pure-css/pure/blob/master/LICENSE.md
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="pure-u-1-4 check" onclick="check_connect('google', 'www.google.com/generate_204')">
|
||||
<div class="pure-u-1-4 check" onclick="check_connect('google', 'https://www.google.com/generate_204')">
|
||||
<div class="block pure-g">
|
||||
<div class="pure-u-8-24">
|
||||
<div class="img-con">
|
||||
|
@ -29,6 +29,7 @@ blinkbox.com
|
||||
brightcove.com
|
||||
caddyserver.com
|
||||
cbs.com
|
||||
cloudflare-dns.com
|
||||
cloudfront.net
|
||||
conviva.com
|
||||
crackle.com
|
||||
@ -37,6 +38,8 @@ crwdcntrl.net
|
||||
cwtv.com
|
||||
disney.com
|
||||
disneyjunior.com
|
||||
dns.google
|
||||
dns.quad9.net
|
||||
easylist-downloads.adblockplus.org
|
||||
edgecastcdn.net
|
||||
edgekey.net
|
||||
@ -57,6 +60,9 @@ githubassets.com
|
||||
githubusercontent.com
|
||||
gnews.org
|
||||
go.com
|
||||
google.com
|
||||
google.com.hk
|
||||
google.com.tw
|
||||
googleapis.com
|
||||
googletagmanager.com
|
||||
googleusercontent.com
|
||||
@ -100,6 +106,7 @@ nflximg.net
|
||||
nflxso.net
|
||||
nflxvideo.net
|
||||
omtrdc.net
|
||||
one.one.one.one
|
||||
open.live.bbc.co.uk
|
||||
openwrt.proxy.ustclug.org
|
||||
openx.net
|
||||
@ -117,6 +124,7 @@ sling.com
|
||||
southpark.cc.com
|
||||
spike.com
|
||||
srip.net
|
||||
stripe.com
|
||||
theplatform.com
|
||||
ttvnw.net
|
||||
turner.com
|
||||
@ -132,7 +140,4 @@ xboxlive.com
|
||||
youtu.be
|
||||
youtube.com
|
||||
ytimg.com
|
||||
dns.google
|
||||
cloudflare-dns.com
|
||||
one.one.one.one
|
||||
dns.quad9.net
|
||||
zerotier.com
|
||||
|
Loading…
x
Reference in New Issue
Block a user