Home / Guides

Server guide

cPanel and WHM server security checklist

A cPanel server is a Linux server plus a control panel plus many customer websites. Each of the three can be the weak spot. This checklist covers the panel settings and points to the Linux checks that go with them.

3 min readUpdated November 2026 by the RootManage teamWorks on Ubuntu, Debian, AlmaLinux and Rocky unless noted

The short answer

Keep cPanel and the operating system updated, run the Security Advisor and fix what it lists, turn on brute-force protection and two-factor login for WHM, use ModSecurity with maintained rules, remove old PHP versions, limit shell access and keep tested backups off the server.

Updates for cPanel and for the system

terminal
sudo /scripts/upcp
sudo dnf check-update

In WHM, open Update Preferences and choose a release tier that suits you, and keep automatic updates on. Menu names differ a little between versions. Also update the operating system packages and restart when the kernel changed. A version of cPanel or the OS that is past its support date should be planned out, not patched around.

Run the Security Advisor

WHM has a Security Advisor under Security Center. It lists problems it can see on the server, such as risky settings and missing protections, with a suggested fix for each. Run it after every big change and treat its list as a to-do list, not as a certificate.

Protect the logins

  • Turn on cPHulk Brute Force Protection (Security Center) so repeated wrong passwords are blocked.
  • Turn on two-factor authentication for WHM and root-level resellers.
  • Use Host Access Control to limit who can reach WHM ports (2087) and SSH, if your own addresses are fixed.
  • Use SSH keys and no password login. See the SSH hardening guide.

Put a web application firewall in front of the sites

ModSecurity with a maintained rule set (a vendor you can pick in WHM under ModSecurity Vendors) blocks a lot of common attacks on WordPress and other scripts. It needs tuning: a rule can block a good plugin. Watch the logs for a few days after you turn it on.

Keep PHP supported

Open MultiPHP Manager and look at the PHP version of each site. Versions that no longer get security fixes should be moved to a supported one, after testing the site. Remove versions nobody uses. Our PHP upgrade guide has the steps.

Limit who can log in to a shell

Most hosting customers do not need SSH. In WHM, Manage Shell Access lets you keep it off by default and turn it on for one account when needed. Fewer shells means fewer places an attacker can run commands after a hacked website.

Mail and spam

  • Set SPF and DKIM for every domain. WHM can do this for you.
  • Limit how many emails an account can send per hour, so one hacked site cannot get the whole server blocked.
  • Watch the mail queue: exim -bpc shows how many messages are waiting.

Backups that leave the server

Use WHM Backup Configuration, send a copy to another server or storage, and restore one account to a test location now and then. See the restore test guide.

The Linux side

The panel does not fix a weak operating system. Check open ports, file permissions, users, cron jobs and kernel settings. The Linux server security checklist lists them.

Let a script check it weekly

The RootManage security audit has deep checks for cPanel and WHM (and Plesk and DirectAdmin) and runs them every week from a read-only script. You can try it first on your own server for free: free Linux security audit. For a server that may already be hacked, see the signs of a hacked cPanel website.

Questions people ask

Does cPanel secure my server by itself?

It gives you tools, and it hardens some defaults. The server still needs updates, a firewall, careful settings and backups that you check.

What does the Security Advisor not check?

It cannot see everything: weak passwords of your customers, vulnerable plugins inside their sites, or what an attacker did after getting in. It is a good start.

Should customers get SSH?

Only when they need it. Keep it off by default and turn it on per account.

Is the RootManage audit a replacement for the Security Advisor?

No, they overlap but are different. Use both. The audit keeps a history, shows a score and alerts you in a dashboard.

Want a person to look at it?

Tell us what you see. We reply with what we think is wrong and what it would take to fix it.