Knowledge Base

How to Configure CSF Firewall to Secure Your VPS

Overview: ConfigServer Security & Firewall (CSF) is the most powerful security plugin for WHM. It protects your VPS from brute-force attacks, unauthorized login attempts, and malicious IP addresses.

Essential Configuration Steps:

  1. Log in to WHM as root.

  2. Go to Plugins -> ConfigServer Security & Firewall.

  3. Click on "Firewall Configuration".

  4. Testing Mode: Ensure TESTING is set to 0 once you are sure of your settings; otherwise, the firewall will stop every 5 minutes.

  5. Port Management: Check TCP_IN and TCP_OUT to ensure only necessary ports (like 80, 443, 2087) are open.

  6. Login Failure Blocking: Look for LF_DAEMON and set it to On. This will automatically block IPs that fail to log in multiple times.

  7. Click Change at the bottom and then Restart csf+lfd.

Quick Action: To whitelist your own IP so you don't get locked out, use the "Quick Allow" box on the main CSF page and enter your IP.

Please rate this article to help us improve our Knowledge Base.

0 0