nekonojita

iptables SSH

May 30th, 2013
588
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.31 KB | None | 0 0
  1. -A INPUT -i eth0 -p tcp -m tcp --dport 22 --tcp-flags FIN,SYN,RST,ACK SYN -m recent --set --name ssh --rsource
  2. -A INPUT -i eth0 -p tcp -m tcp --dport 22 --tcp-flags FIN,SYN,RST,ACK SYN -m recent --rcheck --seconds 30 --hitcount 5 --name ssh --rsource -j DROP
  3. -A INPUT -i eth0 -p tcp -m tcp --dport 22 -j ACCEPT
Advertisement
Add Comment
Please, Sign In to add comment