Insights

Review cPHulk Blocks Weekly Before Locked-Out cPanel Users Flood Support

November 7, 2026
0:00
A customer can't log into cPanel, their phone stopped syncing webmail, and FTP rejects a password they swear is correct. Often the account is fine. cPHulk, the brute-force protection daemon built into cPanel & WHM, has blocked their IP address or their username. Clearing the block fixes today's ticket, but the same people tend to come back. A short weekly review of cPHulk history catches those repeat patterns before they turn into a queue. This guide stays on the command line so every step can be repeated and compared week to week. Take a baseline, read the pattern, make one targeted change, and measure again.
cPHulk watches failed authentication attempts for the services it protects. Depending on version and configuration, those typically include cPanel, WHM, webmail, SSH, FTP, mail retrieval (POP3/IMAP), and SMTP authentication. When failures cross a threshold inside the protection period, it blocks either the source IP or the username being attacked. That second case confuses people. With username-based protection on, a bot hammering exampleuser from many addresses can lock out the real owner from every location, even though the owner never typed a wrong password. With IP-based protection, one person's mistake on a shared office connection can block everyone behind the same public IP. Both look the same to the customer: "my password stopped working." Mail is the most common source of failures that aren't attacks. A customer changes their email password in cPanel, but a laptop, a phone, and an old tablet still hold the previous password and keep retrying in the background. Each retry counts as a failure. The customer sees nothing until the block lands. If you are still deciding whether cPHulk or CSF/LFD should handle SSH on the server, that comparison is covered in cPHulk or CSF/LFD: Which Should Block SSH Brute-Force on a WHM Server?. This guide assumes cPHulk is enabled and staying.
Start by confirming cPHulk is running and recording what is already on the allow and deny lists. Old whitelist entries are worth reading every week. A former office IP that now belongs to someone else bypasses protection completely.
BASH
# Is cPHulk enabled?
whmapi1 cphulk_status

# Current whitelist and blacklist entries
whmapi1 read_cphulk_records list_name=white
whmapi1 read_cphulk_records list_name=black
Next, look at block activity and failed logins. The cphulkd log records block events. The cPanel login log records failed logins to cPanel, WHM, and webmail with the account name and source IP on each line.
BASH
# Recent block events logged by cphulkd
grep -i 'block' /usr/local/cpanel/logs/cphulkd.log | tail -n 50

# IPs that appear most often in block events
grep -i 'block' /usr/local/cpanel/logs/cphulkd.log | grep -oE '([0-9]{1,3}[.]){3}[0-9]{1,3}' | sort | uniq -c | sort -rn | head -n 20

# Recent failed cPanel/WHM/webmail logins
grep 'FAILED LOGIN' /usr/local/cpanel/logs/login_log | tail -n 50

# Failed SMTP authentication attempts seen by Exim
grep 'authenticator failed' /var/log/exim_mainlog | tail -n 20
Log wording varies between cPanel releases, so skim the raw lines once before trusting the grep patterns. Logs also rotate. If you want a clean seven-day window, check how your server rotates these files and include the rotated copy. Dovecot authentication failures land in a different place depending on the OS, usually /var/log/maillog or /var/log/mail.log, or the journal on some systems. Write down two numbers: total block events and the count for the top IP. These are rough, but they give you something concrete to compare against next week. The History Reports tab in WHM's cPHulk page shows the same data in a browser. It works well for a quick look, while the CLI is easier to repeat and diff.
The log lines look similar either way. The pattern around them is what differs. Automated attacks usually show one of two shapes. Either one IP tries many different usernames, often ones that don't exist on the server (admin, test, root, random strings), or many IPs each try the same real username a few times. The second shape is the slow, distributed credential stuffing botnets use to stay under per-IP limits, usually with credentials leaked from other breaches. Hits against root over SSH or WHM from unfamiliar networks fall in the same bucket. Legitimate lockouts look narrower. A single IP, one or two real account names, and failures that start shortly after a password change. Mail failures that repeat at a steady interval are a strong hint of a device retrying a stored password. The decisive check: the same IP has logged in successfully before. Support engineers typically check that last point first, because it settles most cases. If an IP has a history of successful sessions for that account, it is almost certainly the customer. If it has never logged in successfully and is cycling through usernames, it is not.
Once you've confirmed an IP belongs to the customer, there are two different actions. They are not interchangeable. Clearing the failed-login history unblocks that IP now and leaves protection in place. Use this for one-off mistakes, roaming users, and anyone on a dynamic home connection. Whitelisting tells cPHulk to stop counting failures from that IP at all. Reserve it for confirmed static addresses you control, such as your own admin network or a customer's fixed office IP that they've confirmed in writing.
Security warning: A whitelisted IP gets unlimited password guesses. Avoid whitelisting broad ISP or mobile carrier ranges just to stop tickets. Those ranges are shared with strangers, and a compromised machine inside them bypasses cPHulk entirely.
Replace 203.0.113.10 below with the real address. The first command only reads. The others change cPHulk state.
BASH
# Has this IP had successful sessions before? A non-zero count is a good sign
grep -c '203.0.113.10' /usr/local/cpanel/logs/session_log

# Clear failed-login history for one confirmed IP so it can log in again
whmapi1 flush_cphulk_login_history_for_ips ip='203.0.113.10'

# Whitelist only a confirmed static IP, then verify it is on the list
/usr/local/cpanel/scripts/cphulkdwhitelist '203.0.113.10'
whmapi1 read_cphulk_records list_name=white
Unblocking without fixing the cause brings the block back within hours. For mail lockouts, the actual fix is on the customer's side: update the saved password on every device, or remove the stale account from the old tablet. Tell them what to look for. Otherwise the ticket reopens and nothing has changed.
If the review keeps showing legitimate users blocked by small failure counts, the thresholds in WHM's cPHulk Configuration Settings may be too tight for your user base. The main settings are the protection period, the maximum failures per username, the maximum failures per IP, and the separate threshold for a one-day IP block. Exact labels depend on the cPanel version. Change one value at a time and in small steps. Raising the per-IP limit a little gives fumbling users more room. Raising it a lot mostly helps attackers. If the attack pattern is distributed guessing against real usernames, a higher per-IP limit does nothing for legitimate users anyway, and it is worth discussing stronger passwords or two-factor authentication with the account owner instead. Username-based protection is the setting most likely to lock out real owners during an attack. Whether to keep it on depends on how often you see that pattern compared with targeted guessing. After a change, run the same baseline commands a week later and compare. Block events from attack-shaped traffic should stay roughly the same, because the protection still works. Repeat blocks from known customer IPs should drop. If total blocks fall sharply and the attack-shaped IPs disappear from the list, the change may have loosened things more than intended. A weekly pass of ten minutes is usually enough: check the lists, count blocks by IP, confirm or reject the top few against session history, clear or whitelist only what you've verified, and adjust one threshold at most. Keep notes of each week's numbers. Over time, the notes show whether you're reducing lockout tickets or just hiding attacks.

Join My Newsletter & Get Updates!

Get notified whenever a new technical guide, server infrastructure breakdown, or personal reflection goes live, plus a curated weekly digest.