From f53f96d37cfdcf217ec78f29fef5ec7cd11899e5 Mon Sep 17 00:00:00 2001 From: Khachatryan Karen Date: Sun, 9 Feb 2025 13:35:46 +0300 Subject: [PATCH] antiblock: Update to 2.0.1 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 --- net/antiblock/Makefile | 4 ++-- net/antiblock/files/etc/config/antiblock | 2 +- net/antiblock/files/etc/init.d/antiblock | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/net/antiblock/Makefile b/net/antiblock/Makefile index f8101fb21a..121ede38c1 100644 --- a/net/antiblock/Makefile +++ b/net/antiblock/Makefile @@ -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 PKG_LICENSE:=GPL-3.0-or-later diff --git a/net/antiblock/files/etc/config/antiblock b/net/antiblock/files/etc/config/antiblock index cc31500f00..fc4e56b349 100644 --- a/net/antiblock/files/etc/config/antiblock +++ b/net/antiblock/files/etc/config/antiblock @@ -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' diff --git a/net/antiblock/files/etc/init.d/antiblock b/net/antiblock/files/etc/init.d/antiblock index 85d29bf8ee..3d35e2dd97 100644 --- a/net/antiblock/files/etc/init.d/antiblock +++ b/net/antiblock/files/etc/init.d/antiblock @@ -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 -- 2.30.2