antiblock: Update to 2.0.1
authorKhachatryan Karen <karen0734@gmail.com>
Sun, 9 Feb 2025 10:35:46 +0000 (13:35 +0300)
committerTianling Shen <cnsztl@gmail.com>
Sun, 9 Feb 2025 13:36:59 +0000 (21:36 +0800)
Updated hashmap version.
In the code, almost all the url words have been replaced with domain.
Fixed a bug in the service of getting gateway from VPN name.

Signed-off-by: Khachatryan Karen <karen0734@gmail.com>
net/antiblock/Makefile
net/antiblock/files/etc/config/antiblock
net/antiblock/files/etc/init.d/antiblock

index f8101fb21a61ce12ceebd920313341f4f3bde30c..121ede38c11b6df5d1e404b4d171e031724ef839 100644 (file)
@@ -1,13 +1,13 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=antiblock
-PKG_VERSION:=2.0.0
+PKG_VERSION:=2.0.1
 PKG_RELEASE:=1
 
 PKG_SOURCE_PROTO:=git
 PKG_SOURCE_URL:=https://github.com/karen07/antiblock
 PKG_SOURCE_VERSION:=v$(PKG_VERSION)
-PKG_MIRROR_HASH:=3ea495e825edb75bc0bec9010d4b0195442dbcc745fc4d3150ae41ca11e9dfc4
+PKG_MIRROR_HASH:=bfde3c4f5f3ca4f4c8ad679b4d3f367fef3021e6aae61ce2d5f283e6775db8bb
 
 PKG_MAINTAINER:=Khachatryan Karen <karen0734@gmail.com>
 PKG_LICENSE:=GPL-3.0-or-later
index cc31500f00c0a09290ee386e8f48ee7e16d91e55..fc4e56b3491cc3662df73c84a055a6563da6d4e7 100644 (file)
@@ -3,7 +3,7 @@
        #option enabled '0'
        #At least one parameters needs to be filled:
                #option url 'https://antifilter.download/list/domains.lst'
-               #option file '/root/my_urls.txt'
+               #option file '/root/domains'
        #Required parameters:
                #option listen '192.168.1.1:5053'
                #option DNS '1.1.1.1:53'
index 85d29bf8ee3be4f5418acd6ab35a99d1b4490378..3d35e2dd97b3c9e830e0a399d1353e098b674f6a 100644 (file)
@@ -54,7 +54,7 @@ start_service() {
        fi
        [ -n "${_DNS}" ] && procd_append_param command -DNS "${_DNS}"
        if [ -n "${_VPN_name}" ]; then
-               local gateway="$(uci -q get network."${_VPN_name}".addresses | cut -d '/' -f1)"
+               local gateway="$(ip r | grep -v via | grep "dev ${_VPN_name} " | grep src | awk '{print $NF}')"
                procd_append_param command -gateway "$gateway"
        fi