---
title: 'Connection Limit Protection'
url: 'https://docs.danami.com/juggernaut/user-guide/connection-limit-protection'
markdown: 'https://docs.danami.com/juggernaut/user-guide/connection-limit-protection.md'
date: '2026-09-22'
description: 'Connection limit protection configures iptables to offer protection from DOS attacks against specific ports. It can also be used as a way to simply limit resource usage by IP address to specific server services. This option limits the number of new concurrent connections per IP address that can be …'
taxonomy:
  category:
    - docs
  tag:
    - port_flood
---

[](#)  [ Basics ](https://docs.danami.com/juggernaut/)     [ User Guide ](https://docs.danami.com/juggernaut/user-guide)      Connection Limit Protection    

# Connection Limit Protection

Connection limit protection configures iptables to offer protection from DOS attacks against specific ports. It can also be used as a way to simply limit resource usage by IP address to specific server services. This option limits the number of new concurrent connections per IP address that can be made to specific ports.

> > > > > • This feature does not work on servers that do not have the iptables module `xt_connlimit` loaded.
> > > > > • The protection can only be applied to the TCP protocol.
> > > > > • Existing connections are not included in the count, only new SYN packets, i.e. new connections.
> > > > > • Run `/etc/csf/csftest.pl` to check whether this option will function on the server.

## Format

```
port;limit
```

## Example

```
CONNLIMIT = "22;5,80;20"
```

1. Only allow up to 5 concurrent new connections to port 22 per IP address.
2. Only allow up to 20 concurrent new connections to port 80 per IP address.

## Related Files

| File | Description |
|---|---|
| `/etc/csf/csf.conf` | `CONNLIMIT` configuration option |
| `/usr/local/csf/tpl/connectiontracking.txt` | Connection tracking alert template |

## Related Pages

- [Port Flood Protection](https://docs.danami.com/juggernaut/user-guide/port-flood-protection "Port Flood Protection")
- [Port Flood Settings](https://docs.danami.com/juggernaut/settings/firewall/port-flood-settings "Port Flood Settings")

 [ ](https://docs.danami.com/juggernaut/user-guide/port-flood-protection) [](https://docs.danami.com/juggernaut/command-line-interface/firewall/firewall-portflood)

---

## Navigation

- Parent: [User Guide](https://docs.danami.com/juggernaut/user-guide.md)
- Previous: [Port Knocking](https://docs.danami.com/juggernaut/user-guide/port-knocking.md)
- Next: [Port / IP Redirection](https://docs.danami.com/juggernaut/user-guide/port-ip-redirection.md)
