sync with mainline source

This commit is contained in:
CN_SZTL 2020-02-22 13:39:12 +08:00
parent cc94840e57
commit d6962fc12e
No known key found for this signature in database
GPG Key ID: 6850B6345C862176
15 changed files with 122 additions and 78 deletions

View File

@ -1,3 +1,4 @@
1dot1dot1dot1.cloudflare-dns.com
91smartyun.pt
adobe.com
amazonaws.com
@ -9,10 +10,14 @@ backpackers.com.tw
bitfinex.com
buzzfeed.com
clockwise.ee
cloudflare-dns.com
cloudfront.net
coindesk.com
coinsquare.io
cryptocompare.com
dns.google
dns9.quad9.net
doh.opendns.com
dropboxstatic.com
eurecom.fr
gdax.com

View File

@ -71,6 +71,12 @@ config access_control
list wan_fw_ips '91.108.4.0/22'
list wan_fw_ips '91.108.56.0/22'
list wan_fw_ips '109.239.140.0/24'
list wan_fw_ips '1.1.1.1/32'
list wan_fw_ips '1.0.0.1/32'
list wan_fw_ips '8.8.8.8/32'
list wan_fw_ips '8.8.4.4/32'
list wan_fw_ips '9.9.9.9/32'
list wan_fw_ips '146.112.41.2/32'
config server_global
option enable_server '0'

View File

@ -1,3 +1,4 @@
1dot1dot1dot1.cloudflare-dns.com
91smartyun.pt
adobe.com
amazonaws.com
@ -9,10 +10,14 @@ backpackers.com.tw
bitfinex.com
buzzfeed.com
clockwise.ee
cloudflare-dns.com
cloudfront.net
coindesk.com
coinsquare.io
cryptocompare.com
dns.google
dns9.quad9.net
doh.opendns.com
dropboxstatic.com
eurecom.fr
gdax.com

View File

@ -1,7 +1,4 @@
config global
option tunnel_forward '8.8.4.4:53'
option tunnel_address '0.0.0.0'
@ -38,6 +35,12 @@ config access_control
list wan_fw_ips '91.108.4.0/22'
list wan_fw_ips '91.108.56.0/22'
list wan_fw_ips '109.239.140.0/24'
list wan_fw_ips '1.1.1.1/32'
list wan_fw_ips '1.0.0.1/32'
list wan_fw_ips '8.8.8.8/32'
list wan_fw_ips '8.8.4.4/32'
list wan_fw_ips '9.9.9.9/32'
list wan_fw_ips '146.112.41.2/32'
config server_global
option enable_server '0'
@ -71,7 +74,3 @@ config udpspeeder
option timeout '8'
option udpspeeder_enable '0'

View File

@ -8,7 +8,7 @@ local DL = SYS.exec("head -1 /tmp/adbyby/data/lazy.txt | awk -F' ' '{print $3,$4
local DV = SYS.exec("head -1 /tmp/adbyby/data/video.txt | awk -F' ' '{print $3,$4}'") or ""
local NR = SYS.exec("grep -v '^!' /usr/share/adbyby/data/rules.txt | wc -l")
local NU = SYS.exec("cat /usr/share/adbyby/data/user.txt | wc -l")
local UD = SYS.exec("cat /tmp/adbyby.updated") or " "
local UD = NXFS.readfile("/tmp/adbyby.updated") or "1970-01-01 00:00:00"
local ND = SYS.exec("cat /usr/share/adbyby/dnsmasq.adblock | wc -l")
m = Map("adbyby")

View File

@ -164,7 +164,7 @@ start()
[ $enable -eq 0 ] && exit 0
add_cron
[ ! -d "/tmp/adbyby/data" ] && cp -a /usr/share/adbyby /tmp/ && rm -f /tmp/adbyby.updated
/usr/share/adbyby/admem.sh &
/usr/share/adbyby/admem.sh &>/dev/null &
add_rules
/tmp/adbyby/adbyby &>/dev/null &
add_dns

View File

@ -2,7 +2,8 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=luci-app-ssr-plus
PKG_VERSION:=150
PKG_RELEASE:=1
PKG_RELEASE:=2
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)
include $(INCLUDE_DIR)/package.mk

View File

@ -99,21 +99,25 @@ else
retstring ="-1"
end
elseif set == "ip_data" then
refresh_cmd="wget -O- 'http://ftp.apnic.net/apnic/stats/apnic/delegated-apnic-latest' 2>/dev/null| awk -F\\| '/CN\\|ipv4/ { printf(\"%s/%d\\n\", $4, 32-log($5)/log(2)) }' > /tmp/china_ssr.txt"
sret=luci.sys.call(refresh_cmd)
icount = luci.sys.exec("cat /tmp/china_ssr.txt | wc -l")
if sret== 0 and tonumber(icount)>1000 then
oldcount=luci.sys.exec("cat /etc/china_ssr.txt | wc -l")
if tonumber(icount) ~= tonumber(oldcount) then
luci.sys.exec("cp -f /tmp/china_ssr.txt /etc/china_ssr.txt")
retstring=tostring(tonumber(icount))
if (luci.model.uci.cursor():get_first('shadowsocksr', 'global', 'chnroute', '0') == '1') then
refresh_cmd="wget-ssl --no-check-certificate -O - " .. luci.model.uci.cursor():get_first('shadowsocksr', 'global', 'chnroute_url', 'https://pexcn.me/daily/chnroute/chnroute.txt') .. ' > /tmp/china_ssr.txt 2>/dev/null'
else
retstring ="0"
refresh_cmd="wget -O- 'http://ftp.apnic.net/apnic/stats/apnic/delegated-apnic-latest' 2>/dev/null| awk -F\\| '/CN\\|ipv4/ { printf(\"%s/%d\\n\", $4, 32-log($5)/log(2)) }' > /tmp/china_ssr.txt"
end
else
retstring ="-1"
end
luci.sys.exec("rm -f /tmp/china_ssr.txt ")
sret=luci.sys.call(refresh_cmd)
icount = luci.sys.exec("cat /tmp/china_ssr.txt | wc -l")
if sret== 0 and tonumber(icount)>1000 then
oldcount=luci.sys.exec("cat /etc/china_ssr.txt | wc -l")
if tonumber(icount) ~= tonumber(oldcount) then
luci.sys.exec("cp -f /tmp/china_ssr.txt /etc/china_ssr.txt")
retstring=tostring(tonumber(icount))
else
retstring ="0"
end
else
retstring ="-1"
end
luci.sys.exec("rm -f /tmp/china_ssr.txt ")
else
if nixio.fs.access("/usr/bin/wget-ssl") then
refresh_cmd="wget-ssl --no-check-certificate -O - ".. luci.model.uci.cursor():get_first('shadowsocksr', 'global', 'adblock_url','https://easylist-downloads.adblockplus.org/easylistchina+easylist.txt') .." > /tmp/adnew.conf"

View File

@ -54,6 +54,16 @@ o.rmempty = false
o = s:option(Value, "adblock_url", translate("adblock_url"))
o.default = "https://easylist-downloads.adblockplus.org/easylistchina+easylist.txt"
-- [[ chnroute ]]
s = m:section(TypedSection, "global", translate("Chnroute Setting"))
s.anonymous = true
o = s:option(Flag, "chnroute", translate("Enable custom chnroute"))
o.rmempty = false
o = s:option(Value, "chnroute_url", translate("Update url"))
o.default = "https://cdn.jsdelivr.net/gh/17mon/china_ip_list/china_ip_list.txt"
-- [[ SOCKS Proxy ]]--
if nixio.fs.access("/usr/bin/srelay") then
s = m:section(TypedSection, "socks5_proxy", translate("SOCKS Proxy"))

View File

@ -337,6 +337,15 @@ msgstr "启用进程自动守护"
msgid "Advertising Data"
msgstr "【广告屏蔽】数据库"
msgid "Chnroute Setting"
msgstr "国内IP段数据库更新设置"
msgid "Enable custom chnroute"
msgstr "启用自定义更新地址"
msgid "Update url"
msgstr "更新链接"
msgid "DNS Server IP and Port"
msgstr "DNS服务器地址和端口"

View File

@ -1,3 +1,4 @@
1dot1dot1dot1.cloudflare-dns.com
91smartyun.pt
adobe.com
amazonaws.com
@ -9,10 +10,14 @@ backpackers.com.tw
bitfinex.com
buzzfeed.com
clockwise.ee
cloudflare-dns.com
cloudfront.net
coindesk.com
coinsquare.io
cryptocompare.com
dns.google
dns9.quad9.net
doh.opendns.com
dropboxstatic.com
eurecom.fr
gdax.com

View File

@ -27,6 +27,12 @@ config access_control
list wan_fw_ips '91.108.4.0/22'
list wan_fw_ips '91.108.56.0/22'
list wan_fw_ips '109.239.140.0/24'
list wan_fw_ips '1.1.1.1/32'
list wan_fw_ips '1.0.0.1/32'
list wan_fw_ips '8.8.8.8/32'
list wan_fw_ips '8.8.4.4/32'
list wan_fw_ips '9.9.9.9/32'
list wan_fw_ips '146.112.41.2/32'
config server_global
option enable_server '0'

View File

@ -42,13 +42,17 @@ else
end
log('正在更新【国内IP段】数据库')
refresh_cmd="wget -O- 'http://ftp.apnic.net/apnic/stats/apnic/delegated-apnic-latest' 2>/dev/null| awk -F\\| '/CN\\|ipv4/ { printf(\"%s/%d\\n\", $4, 32-log($5)/log(2)) }' > /tmp/china_ssr.txt"
if (ucic:get_first('shadowsocksr', 'global', 'chnroute','0') == '1' ) then
refresh_cmd="wget-ssl --no-check-certificate -O - ".. ucic:get_first('shadowsocksr', 'global', 'chnroute_url','https://cdn.jsdelivr.net/gh/17mon/china_ip_list/china_ip_list.txt') .." > /tmp/china_ssr.txt 2>/dev/null"
else
refresh_cmd="wget -O- 'http://ftp.apnic.net/apnic/stats/apnic/delegated-apnic-latest' 2>/dev/null| awk -F\\| '/CN\\|ipv4/ { printf(\"%s/%d\\n\", $4, 32-log($5)/log(2)) }' > /tmp/china_ssr.txt"
end
sret=luci.sys.call(refresh_cmd)
icount = luci.sys.exec("cat /tmp/china_ssr.txt | wc -l")
if sret== 0 then
if sret== 0 then
icount = luci.sys.exec("cat /tmp/china_ssr.txt | wc -l")
if tonumber(icount)>1000 then
oldcount=luci.sys.exec("cat /etc/china_ssr.txt | wc -l")
oldcount=luci.sys.exec("cat /etc/china_ssr.txt | wc -l")
if tonumber(icount) ~= tonumber(oldcount) then
luci.sys.exec("cp -f /tmp/china_ssr.txt /etc/china_ssr.txt")
-- retstring=tostring(math.ceil(tonumber(icount)/2))
@ -57,7 +61,7 @@ icount = luci.sys.exec("cat /tmp/china_ssr.txt | wc -l")
log('你已经是最新数据,无需更新!')
end
else
log('更新失败!')
log('更新失败!')
end
luci.sys.exec("rm -f /tmp/china_ssr.txt")
else

View File

@ -1,39 +1,42 @@
#
# Copyright (C) 2014 OpenWrt-dist
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
#
include $(TOPDIR)/rules.mk
PKG_NAME:=tcping
PKG_VERSION:=0.2
PKG_RELEASE=1
PKG_VERSION:=0.1
PKG_RELEASE:=2
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=https://github.com/coolsnowwolf/tcping
PKG_SOURCE_URL:=https://github.com/jlyo/tcping.git
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
PKG_SOURCE_VERSION:=d890cc1bd8e3951390ceeff1ccb092a5d802850c
PKG_SOURCE_VERSION:=79ef6f85d7147d33d0835fac060618ab136503c8
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MAINTAINER:=coolsnowwolf <coolsnowwolf@gmail.com>
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)/$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
include $(INCLUDE_DIR)/package.mk
define Package/tcping
SECTION:=net
CATEGORY:=Network
DEPENDS:=+libnet-1.2.x
TITLE:=Ping look-alike that uses TCP SYN packets to get around firewalls and ICMP blackholes
SECTION:=net
CATEGORY:=Network
TITLE:=tcping measures the latency of a tcp-connection
URL:=https://github.com/jlyo/tcping
endef
define Package/tcping/description
Ping look-alike that uses TCP SYN packets to get around firewalls and ICMP blackholes
endef
define Build/Compile
$(MAKE) -C $(PKG_BUILD_DIR) \
$(TARGET_CONFIGURE_OPTS) \
CFLAGS="$(TARGET_CFLAGS) -I$(STAGING_DIR)/usr/lib/libnet-1.2.x/include -L$(STAGING_DIR)/usr/lib/libnet-1.2.x/lib" \
INSTALL_PROG=":"
define Package/tcping/conffiles
endef
define Package/tcping/install
$(INSTALL_DIR) $(1)/usr/bin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/tcpping $(1)/usr/bin/tcping
$(INSTALL_DIR) $(1)/usr/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/tcping $(1)/usr/sbin
endef
$(eval $(call BuildPackage,tcping))

View File

@ -13,41 +13,28 @@
# List of hosts that supply bogus NX domain results
# bogus-nxdomain [ip/subnet]
speed-check-mode ping,tcp:80
speed-check-mode tcp:80,ping
server 140.143.226.193
server 140.143.65.193
server 202.141.178.13:5353
server 202.38.93.153:5353
server 202.141.162.123:5353
server 208.67.222.222:5353 -group fq_dns
server 208.67.220.220:5353 -group fq_dns
server 2001:da8::666
server 2001:4860:4860::8888 -group fq_dns
server 2001:4860:4860::8844 -group fq_dns
server 2606:4700:4700::1111 -group fq_dns
server 2606:4700:4700::1001 -group fq_dns
server-tcp 9.9.9.9 -group fq_dns
server-tcp 8.8.8.8 -group fq_dns
server-tcp 8.8.4.4 -group fq_dns
server-tcp 2001:4860:4860::8888 -group fq_dns
server-tcp 2001:4860:4860::8844 -group fq_dns
server-tcp 1.1.1.1 -group fq_dns
server-tcp 1.0.0.1 -group fq_dns
server-tcp 2606:4700:4700::1111 -group fq_dns
server-tcp 2606:4700:4700::1001 -group fq_dns
server-tcp 9.9.9.9 -group fq_dns -exclude-default-group
server-tcp 8.8.8.8 -group fq_dns -exclude-default-group
server-tcp 8.8.4.4 -group fq_dns -exclude-default-group
server-tcp 1.1.1.1 -group fq_dns -exclude-default-group
server-tcp 1.0.0.1 -group fq_dns -exclude-default-group
server-tls 8.8.8.8 -host-name dns.google -group fq_dns
server-tls 8.8.4.4 -host-name dns.google -group fq_dns
server-tls 2001:4860:4860::8888 -host-name dns.google -group fq_dns
server-tls 2001:4860:4860::8844 -host-name dns.google -group fq_dns
server-tls dns.google -group fq_dns
server-tls 1.1.1.1 -host-name 1dot1dot1dot1.cloudflare-dns.com -group fq_dns
server-tls 1.0.0.1 -host-name 1dot1dot1dot1.cloudflare-dns.com -group fq_dns
server-tls 2606:4700:4700::1111 -host-name 1dot1dot1dot1.cloudflare-dns.com -group fq_dns
server-tls 2606:4700:4700::1001 -host-name 1dot1dot1dot1.cloudflare-dns.com -group fq_dns
server-tls 1dot1dot1dot1.cloudflare-dns.com -group fq_dns
server-tls dns.233py.com
server-tls 8.8.8.8 -host-name dns.google -group fq_dns -exclude-default-group
server-tls 8.8.4.4 -host-name dns.google -group fq_dns -exclude-default-group
server-tls dns.google -group fq_dns -exclude-default-group
server-tls 1.1.1.1 -host-name 1dot1dot1dot1.cloudflare-dns.com -group fq_dns -exclude-default-group
server-tls 1.0.0.1 -host-name 1dot1dot1dot1.cloudflare-dns.com -group fq_dns -exclude-default-group
server-tls 1dot1dot1dot1.cloudflare-dns.com -group fq_dns -exclude-default-group
server-https https://202.141.178.13/resolve -host-name neatdns.ustclug.org -http-host neatdns.ustclug.org
server-https https://202.38.93.153/resolve -host-name neatdns.ustclug.org -http-host neatdns.ustclug.org
@ -56,11 +43,11 @@ server-https https://115.159.131.230/resolve -host-name dns.rubyfish.cn -http-ho
server-https https://dns.rubyfish.cn/dns-query
server-https https://45.77.180.10/resolve -host-name dns.containerpi.com -http-host dns.containerpi.com
server-https https://dns.containerpi.com/dns-query
server-https https://9.9.9.9/dns-query -host-name dns9.quad9.net -http-host dns9.quad9.net -group fq_dns
server-https https://dns9.quad9.net/dns-query -group fq_dns
server-https https://1.1.1.1/dns-query -group fq_dns
server-https https://1.0.0.1/dns-query -group fq_dns
server-https https://cloudflare-dns.com/dns-query -group fq_dns
server-https https://146.112.41.2/dns-query -host-name doh.opendns.com -http-host doh.opendns.com -group fq_dns
server-https https://2620:119:fc::2/dns-query -host-name doh.opendns.com -http-host doh.opendns.com -group fq_dns
server-https https://doh.opendns.com/dns-query -group fq_dns
server-https https://i.233py.com/dns-query
server-https https://9.9.9.9/dns-query -host-name dns9.quad9.net -http-host dns9.quad9.net -group fq_dns -exclude-default-group
server-https https://dns9.quad9.net/dns-query -group fq_dns -exclude-default-group
server-https https://1.1.1.1/dns-query -group fq_dns -exclude-default-group
server-https https://1.0.0.1/dns-query -group fq_dns -exclude-default-group
server-https https://cloudflare-dns.com/dns-query -group fq_dns -exclude-default-group
server-https https://146.112.41.2/dns-query -host-name doh.opendns.com -http-host doh.opendns.com -group fq_dns -exclude-default-group
server-https https://doh.opendns.com/dns-query -group fq_dns -exclude-default-group