1
0
Fork 0
mirror of https://github.com/Ysurac/openmptcprouter-feeds.git synced 2025-03-09 15:40:03 +00:00

Fix shadowsocks iptables rules

This commit is contained in:
Ycarus (Yannick Chabanois) 2021-01-27 18:18:50 +01:00
parent a0da499c10
commit b0e38240cc
3 changed files with 21 additions and 15 deletions

View file

@ -1,6 +1,7 @@
#!/bin/sh /etc/rc.common
#
# Copyright (C) 2017-2019 Yousong Zhou <yszhou4tech@gmail.com>
# Copyright (C) 2019-2021 Ycarus (Yannick Chabanois) <ycarus@zugaina.org> for OpenMPTCProuter
#
# This is free software, licensed under the GNU General Public License v3.
# See /LICENSE for more information.
@ -314,6 +315,10 @@ stop_service() {
rm -rf "$ss_confdir"
}
reload_service() {
restart "$@"
}
rules_exist() {
[ -n "$(iptables -t nat -L -n | grep ssr)" ] && return 0
return 1