centos ddos test and protection

is there any secure software for this ?
LVL 1
CahitEyAsked:
Who is Participating?
 
liddlerCommented:
for a specific port add --dport 80
for port 80

The code above creates a chain called syn-flood (iptables -N syn-flood), then adds input packets type tcp any port that are syn type packets ( iptables -A INPUT -p tcp --syn -j syn-flood) then adds 1 syn per second in bursts of 4 (iptables  -A syn-flood -m limit --limit 1/s --limit-burst 4 -j RETURN) then drops them  (iptables  -A syn-flood -j DROP)
this is a very simple example
there is an excellent example here:
http://www.webhostingtalk.com/archive/index.php/t-355411.html

and here's a bit more on dropping other type of packet as well as plain syns

http://www.webhostingtalk.com/showthread.php?s=&threadid=363499
0
 
liddlerCommented:
Do you mean something to prevent a centos server being DDoS attacked?  IF so you can start with iptables (the firewall) this has some DDoS protection, such as rate limiting, flood prevention and black / white listing capabilities
0
 
CahitEyAuthor Commented:
could you please describe a little more about how to ?
0
 
liddlerCommented:
Assuming you are already using iptables as your firewall, you can add:
iptables -N syn-flood
iptables -A INPUT -p tcp --syn -j syn-flood
iptables  -A syn-flood -m limit --limit 1/s --limit-burst 4 -j RETURN
iptables  -A syn-flood -j DROP

or you may want to limit it to specific ports and / or hosts
0
 
CahitEyAuthor Commented:
how could i limit ddos to a specific port or host ?
i am using ip tables yes, but what exactly do this codes
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.