Skip to content

CSF or cPHulk for brute-force defense on cPanel — when each fits

Both CSF/LFD and cPHulk block brute-force logins on cPanel. They are not redundant — here is how to choose, and when running both makes sense.

cPanel ships cPHulk for brute-force defense. CSF/LFD has been the operator’s default for years. New admins ask which to use; experienced admins ask why they should not run both. The short answer: cPHulk handles the cPanel/WHM login surfaces natively, CSF/LFD watches the rest of the system, and together they cover gaps each leaves alone.

What’s happening

cPHulk integrates with cPanel/WHM auth daemons. It can lock accounts at the application level, support 1-minute, 5-minute, and 24-hour brute-force protection windows, and whitelist IPs through its own UI. CSF/LFD reads log files and writes iptables blocks. cPHulk does not write firewall rules unless you configure it to do so; CSF does not understand application-layer locking of a cPanel account.

How to verify

cphulk_status
whmapi1 cphulk_status_check
csf -l | grep -c "DROP"
cat /var/cpanel/hulkd/conf | grep -E "(brute|excessive|ipv4)"
csf -ta | head

If cPHulk is on and CSF is on but cphulkd has no IP-blocking rules merged into iptables, the two are running independently — which is fine.

The fix

  1. Run cPHulk for the cPanel/WHM login surface. Enable it in WHM > Security Center > cPHulk Brute Force Protection. Set Brute Force Protection and IP Based Brute Force Protection both on.
  2. Run CSF/LFD for everything else — SSH, mail, FTP, custom apps. CSF’s LFD watchers are far broader than cPHulk’s reach.
  3. Decide whether cPHulk should also write IP blocks to the firewall. WHM > cPHulk > Configuration Settings > Block IP addresses at the firewall level is the toggle. Leave it off if you want CSF to be the single source of truth, on if you want fast network-layer enforcement.
  4. Whitelist your management IPs in both systems. They are independent allow lists and one without the other is a lockout waiting to happen.
  5. Tune cPHulk thresholds before customers complain. The default 5 failed in 5 minutes is reasonable; the 24-hour lockout is more aggressive than most workflows tolerate.

For environments where this needs to stay consistent across a fleet, Stack Harbor handles brute-force defense under cPanel server administration.