~修复部分设备因iptables版本过低导致ipv6dns劫持失效的问题
~修复安装脚本始终解压失败的bug
This commit is contained in:
juewuy 2023-03-19 09:42:45 +08:00
parent d0918f170c
commit 0d8c403752
6 changed files with 7 additions and 8 deletions

Binary file not shown.

Binary file not shown.

View File

@ -2,5 +2,5 @@ clashnet_v=v1.7.6
clashpre_v=2022.11.25
clash_v=v1.7.1
meta_v=v1.14.2
versionsh=1.7.3
GeoIP_v=20230318
versionsh=1.7.3b

View File

@ -55,15 +55,14 @@ gettar(){
echo -----------------------------------------------
echo 开始解压文件!
mkdir -p $clashdir > /dev/null
tar -zxf '/tmp/ShellClash.tar.gz' -C $clashdir/
[ $? -ne 0 ] && tar -zxf --no-same-owner '/tmp/ShellClash.tar.gz' -C $clashdir/
if [ $? -ne 0 ];then
tar -zxf '/tmp/ShellClash.tar.gz' -C $clashdir/ || tar -zxf --no-same-owner '/tmp/ShellClash.tar.gz' -C $clashdir/
if [ -f $clashdir/init.sh ];then
source $clashdir/init.sh >/dev/null
else
rm -rf /tmp/ShellClash.tar.gz
$echo "\033[33m文件解压失败\033[0m"
error_down
exit 1
else
source $clashdir/init.sh >/dev/null
fi
fi
}

View File

@ -1,7 +1,7 @@
#!/bin/sh
# Copyright (C) Juewuy
version=1.7.3
version=1.7.3b
setdir(){
dir_avail(){

View File

@ -572,7 +572,7 @@ start_ipt_dns(){
fi
iptables -t nat -I PREROUTING -p udp --dport 53 -j clash_dns
#ipv6DNS
if [ -n "$(lsmod | grep 'ip6table_nat')" ];then
if [ -n "$(lsmod | grep 'ip6table_nat')" -a -n "$(lsmod | grep 'xt_nat')" ];then
ip6tables -t nat -N clashv6_dns > /dev/null 2>&1
if [ "$macfilter_type" = "白名单" -a -n "$(cat $clashdir/mac)" ];then
#mac白名单