Add some essential rules
This commit is contained in:
parent
940742bea5
commit
df18c4761a
|
|
@ -4,6 +4,14 @@
|
|||
echo "Configure IPTables"
|
||||
|
||||
#run iptables commands
|
||||
iptables -A INPUT -j DROP -p udp --dport 5060 -m string --string "friendly-scanner" --algo bm
|
||||
iptables -A INPUT -j DROP -p udp --dport 5060 -m string --string "sipcli/" --algo bm
|
||||
iptables -A INPUT -j DROP -p tcp --dport 5060 -m string --string "friendly-scanner" --algo bm
|
||||
iptables -A INPUT -j DROP -p tcp --dport 5060 -m string --string "sipcli/" --algo bm
|
||||
iptables -A INPUT -j DROP -p udp --dport 5080 -m string --string "friendly-scanner" --algo bm
|
||||
iptables -A INPUT -j DROP -p udp --dport 5080 -m string --string "sipcli/" --algo bm
|
||||
iptables -A INPUT -j DROP -p tcp --dport 5080 -m string --string "friendly-scanner" --algo bm
|
||||
iptables -A INPUT -j DROP -p tcp --dport 5080 -m string --string "sipcli/" --algo bm
|
||||
iptables -A INPUT -i lo -j ACCEPT
|
||||
iptables -A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT
|
||||
iptables -A INPUT -p tcp --dport 22 -j ACCEPT
|
||||
|
|
@ -23,4 +31,4 @@ iptables -P OUTPUT ACCEPT
|
|||
#answer the questions for iptables persistent
|
||||
echo iptables-persistent iptables-persistent/autosave_v4 boolean true | debconf-set-selections
|
||||
echo iptables-persistent iptables-persistent/autosave_v6 boolean true | debconf-set-selections
|
||||
apt-get install -y --force-yes iptables-persistent
|
||||
apt-get install -y --force-yes iptables-persistent
|
||||
|
|
|
|||
Loading…
Reference in New Issue