#!bin/sh
#Menghapus semua Rule
iptables -F
iptables -X
iptables -P INPUT ACCEPT
iptables -P OUTPUT ACCEPT
iptables -P FORWARD ACCEPT
#blok paket syn yang dicurigai jahat
iptables -N synjahat
iptables -A INPUT -p tcp --syn -j synjahat
iptables -A synjahat -m limit --limit 1/s --limit-burst 3 -j ACCEPT
iptables -A synjahat -j DROP
#blok paket ping(icmp) yang dicurigai jahat
iptables -N pingjahat
iptables -A INPUT -p icmp -j pingjahat
iptables -A pingjahat -m limit --limit 1/s --limit-burst 2 -j ACCEPT
iptables -A pingjahat -j DROP
save as antisynflood-attack.sh, then chmod 777 ./antisynflood-attack.sh then execute sh ./antisynflood-attack.sh or make start-up on /etc/rc.local
0 comments:
Post a Comment