Enable SSH and WHM login Alert emails

We can enable SSH and WHM login alerts to your email accounts. For security reason, it is necessary to enable these options. Use this security knowledge base to configure security options.

Enable SSH and WHM login Alert emails


Enable WHM login Alerts

You can enable this option in CSF firewall configuration.


WHM >> Plugins >> ConfigServer Security&Firewall > csf – ConfigServer Firewall”.

Just click the “Firewall Configuration

# Send an email alert if anyone accesses WHM via root. An IP address will be

# reported again 1 hour after the last tracked access (or if lfd is restarted)


Enable SSH login Alerts

Login to your server as root user

cd /root

vi .bashrc

Scroll to the end of the file then add the following:

echo ‘ALERT – Root Shell Access (ServerName) on:’ `date` `who` | mail -s “Alert: Root Access from `who | cut -d'(‘ -f2 | cut -d’)’ -f1`” your@yourdomain.com

Replace YourServerName with the handle for your actual server
Replace you@yourdomain.com with your actual email address

Save that file.

  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

Prevent users Creating Certain Domains

How to prevent user creating certain domains You can use cPanel & WHM to prevent users...

Email server troubleshooting

Email / Exim server troubleshooting techniques. You can use the following email server...

cPanel Security Advisor Addon

This security advisor addon has only been tested on 11.38. Installing this addon is easy, using...

Powered by WHMCompleteSolution