Limit the number of connections to a port
by Jason.nix from LinuxQuestions.org on (#6JHXY)
Hello,
I want only 10 different IP addresses to connect to a port. Which of the following iptables rules is correct?
Code:# iptables -A INPUT -p tcp --syn -dport XXY -m iplimit --iplimit-above 10 -J REJECTOr:
Code:# iptables -A INPUT -p tcp --dport XXY -m connlimit --connlimit-above 10 --connlimit-mask 0 -j REJECTThank you.
I want only 10 different IP addresses to connect to a port. Which of the following iptables rules is correct?
Code:# iptables -A INPUT -p tcp --syn -dport XXY -m iplimit --iplimit-above 10 -J REJECTOr:
Code:# iptables -A INPUT -p tcp --dport XXY -m connlimit --connlimit-above 10 --connlimit-mask 0 -j REJECTThank you.