From c1e6c26fde4aecfcccc2beae0e8f48b29424be19 Mon Sep 17 00:00:00 2001 From: SunBK201 Date: Wed, 10 Nov 2021 19:17:42 +0800 Subject: [PATCH] feat(init): ua2f auto start --- files/ua2f.config | 2 +- files/ua2f.init | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/files/ua2f.config b/files/ua2f.config index db1677dd..9dbc750e 100644 --- a/files/ua2f.config +++ b/files/ua2f.config @@ -1,6 +1,6 @@ config ua2f 'enabled' - option enabled '0' + option enabled '1' config ua2f 'firewall' option handle_fw '1' diff --git a/files/ua2f.init b/files/ua2f.init index 02672b9f..695d4780 100755 --- a/files/ua2f.init +++ b/files/ua2f.init @@ -1,6 +1,7 @@ #!/bin/sh /etc/rc.common # Copyright (C) 2020 Zxilly # Copyright (C) 2021 Tianling Shen +# Copyright (C) 2021 SunBK201 USE_PROCD=1 @@ -50,6 +51,7 @@ start_service() { $IPT_M -A FORWARD -p tcp -m conntrack --ctdir ORIGINAL -j ua2f $IPT_M -A FORWARD -p tcp -m conntrack --ctdir REPLY + # 处理流向内网的流量 [ "$handle_intranet" -eq "1" ] && { local wan="$(route -n | grep UG | awk '{print $2}')"