fix blacklist
This commit is contained in:
parent
17cc54b85f
commit
76deffe6f4
@ -4,8 +4,8 @@ BLACKLIST=/etc/sentinel/blacklist
|
|||||||
chain_count=$(iptables -L BLACKLIST -n | wc -l)
|
chain_count=$(iptables -L BLACKLIST -n | wc -l)
|
||||||
if [ ${chain_count} -eq 0 ]; then
|
if [ ${chain_count} -eq 0 ]; then
|
||||||
iptables -N BLACKLIST
|
iptables -N BLACKLIST
|
||||||
iptables -A INPUT -p tcp -m tcp --dport 80 -j BLACKLIST
|
iptables -I INPUT 1 -p tcp -m tcp --dport 80 -j BLACKLIST
|
||||||
iptables -A INPUT -p tcp -m tcp --dport 443 -j BLACKLIST
|
iptables -I INPUT 1 -p tcp -m tcp --dport 443 -j BLACKLIST
|
||||||
|
|
||||||
fi
|
fi
|
||||||
if [ ! -f ${BLACKLIST} ]; then
|
if [ ! -f ${BLACKLIST} ]; then
|
||||||
|
Loading…
x
Reference in New Issue
Block a user