Article 6JHXY Limit the number of connections to a port

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.
External Content
Source RSS or Atom Feed
Feed Location https://feeds.feedburner.com/linuxquestions/latest
Feed Title LinuxQuestions.org
Feed Link https://www.linuxquestions.org/questions/
Reply 0 comments