This article is a step-by-step guide on what to do when an account under your reseller plan sends spam, hosts malware, or has been compromised, using WHM.
Priority: Act fast. A compromised account can affect server reputation, block email for other clients, and trigger blacklists (RBL).
Warning signs
- Notice from the provider or server regarding mass email sending.
- Very large mail queue in Mail Queue Manager.
- Client reports redirects, ads, or content they did not upload.
- Google or browsers flag the site as dangerous.
- Sudden spike in disk usage, CPU, or transfer in List Accounts.
- Suspicious recent files (
.phpwith random names inuploads, etc.).
Step 1: Contain (immediate)
- Log in to WHM → Account Functions → Manage Account Suspension.
- Suspend the affected account (preserves data; cuts off web and email).
- Note in Reason the cause (e.g., “spam 03/12/2026” or “malware reported”).
If the provider has already suspended the account, do not unsuspend it until cleaned.
Step 2: Change credentials
- WHM → Account Functions → Password Modification → new strong cPanel password.
- From the account's cPanel (or ask the client): change passwords for all email accounts and FTP.
- If using WordPress or another CMS: change admin password and keys in
wp-config.phpif they were exposed.
Step 3: Review email and queue
- WHM → Email → Mail Queue Manager (if available): identify sender and volume.
- WHM → Email → Modify Max Email per Hour: lower the limit temporarily if needed.
- Check if there are PHP scripts sending mail (
mail()in unknown files).
Step 4: Review files (cPanel via WHM)
- List Accounts → cPanel → File Manager.
- Search in
public_html,wp-content/uploads,tmp: recent.phpfiles with weird names. - Check
.htaccessfor redirects to external domains. - Check for outdated or nulled WordPress plugins/themes.
Step 5: Clean or restore
| Situation | Action |
|---|---|
| You have a recent clean backup | Restore files/database from a backup prior to the incident + new passwords. |
| Contained infection (one file) | Delete the malicious file, update CMS/plugins, change keys. |
| Widespread or unknown infection | Escalate to provider support or professional cleaning service. |
Do not: Unsuspend the account without cleaning; restore a backup from the same day as the hack (may include malware); ignore the provider's notice.
Step 6: After cleaning
- Update WordPress, plugins, themes, and PHP if applicable.
- Verify SSL/TLS Status and that the site loads properly.
- Check Email Deliverability in cPanel (SPF/DKIM).
- Unsuspend only when the site and email are clean.
- Inform the client about best practices (passwords, updates).
When to escalate to support
- The server remains blacklisted after cleaning.
- You cannot find the origin of the spam or malware.
- The provider demands intervention before reactivating.
- There are signs of root access or full server compromise.
Open a ticket from the client portal with domain, cPanel username, and incident time. You can also consult via the site's online chat.
