Do we have a setting like the following to protect us from this?
Example 3: Protect against DoS attacks
You can use iptables to protect your server from Denial of Service (DoS) attacks. For example, you can add a rule to the “INPUT” chain to limit the number of connections from a single IP address:
sudo iptables -A INPUT -p tcp --syn -m connlimit --connlimit-above 20 -j DROP
This rule would drop any incoming TCP packets that initiate a new connection and are not part of an existing connection if the number of connections from the source IP address is above 20.
In summary, iptables chains and targets provide a powerful way to control network traffic by filtering packets based on various criteria. By creating rules that specify which packets are allowed and which are denied, you can secure your system and protect it from unwanted traffic or attacks.