ConfigServer Firewall (CSF) is my preferred alternative to iptables. It’s very easy to install.
First, we need to prepare yum. You’ll want to be root for this:
yum update yum install -y perl bind-utils
Next, download and install CSF from its source:
cd /usr/src wget https://download.configserver.com/csf.tgz tar -xzf csf.tgz cd csf sh install.sh
Once that’s done, check whether the installation has worked:
After that has run successfully, you need to turn off CSF’s training mode:
TESTING setting, and set it to
If you’ll be using CSF with Docker, now is the time to set the
DOCKER flag to
Restart CSF with this command:
Now CSF has been installed and configured successfully!