How can I enable Cloudflare support using Juggernaut Firewall?

As Cloudflare is a reverse proxy, any attacking IP addresses (so far as iptables is concerned) come from the Cloudflare IP's. To counter this, an Apache module mod_cloudflare is available that obtains the true attackers IP from a custom HTTP header record (similar functionality is available for other HTTP daemons.

Restoring Original Visitor IP Addresses

Install the mod_cloudflare module. This will make sure that the users real IP address is reported correctly in the web server logs.

Centos/RHEL/CloudLinux

Plesk maintains their own mod_cloudflare pacakges so it should be a simple process to install.

// install the mod_cloudflare package
yum install mod_cloudflare

// restart apache
systemctl restart httpd

Debian/Ubuntu

Plesk does not maintain the mod_cloudflare module on Debian/Ubuntu so users must use install the repository provided by Cloudflare. See https://pkg.cloudflare.com/ for more information.

Add the Cloudflare Network Ranges To Ignore

  1. Navigate to Juggernaut Firewall -> Ignore
  2. Click the Advanced button and add the Cloudflare network ranges to ignore so the login failure daemon will never block them.
  3. Click the Update button to save your settings.
  4. Click the Restart button to restart the firewall and login failure daemon.

Enable Cloudflare Support

  1. Navigate to Juggernaut Firewall -> Settings -> Other -> Cloudflare Settings
  2. Check the Cloudflare firewall checkbox to enable Cloudflare support.
  3. Click the Update button to save your settings.
  4. Click the Restart button to restart the firewall and login failure daemon.

Add Your CloudFlare API Keys

  1. Navigate to Juggernaut Firewall -> Settings -> Other -> Cloudflare Settings -> Cloudflare Users
  2. Click the Add button on the grid to add any Cloudflare user API keys (CSF uses the older API keys not API tokens)
  3. Click the Submit button to save your settings.
  4. Click the Restart button on the grid to restart the firewall and login failure daemon.

Add the Cloudflare Actions Widget To The Dashboard

  1. Navigate to Juggernaut Firewall -> Dashboard
  2. Click the Add Widget button on the top right of the dashboard.
  3. Click the Add Widget button below the Cloudflare Actions widget.

  • cloudflare
  • 1 Users Found This Useful
Was this answer helpful?

Related Articles

How can I raise the open file limit for the login failure daemon?

The login failure daemon can crash if you are monitoring a lot of domains in Plesk and are...

How can I test to make sure that the OS has all the required kernel modules required for Juggernaut Firewall?

Test from the Juggernaut Extension You can run the firewall test by going to Juggernaut Firewall...

How can I adjust the attack triggers used by the login failure daemon?

To Adjust Login Failure Triggers Navigate to Juggernaut Firewall -> Settings -> Login...

Where are the configuration files for Juggernaut Firewall located?

Configuration files are located in the /etc/csf/ directory with the main firewall configuration...

How can I use Juggernaut Firewall to monitor a list of directories?

Enter the Directories You Want To Monitor Navigate to Juggernaut Firewall -> Settings ->...