wget http://www.configserver.com/free/csf.tgz
tar zxfv csf.tgz
cd csf
./install.cpanel.sh
csf firewall installation completed.

Configuration:
===
vi /etc/csf/csf.conf

1. Configure the TCP_IN, TCP_OUT, UDP_IN and UDP_OUT options in the csf configuration to suite your server
2. Set TESTING to 0
3. Restart csf and lfd
#/etc/init.d/csf start or csf -r
===

To check the csf is installed or not:
===
Cpanel WHM >> ConfigServer Security&Firewall.
At the top : Firewall Status: Enabled and Running.
===

To remove the csf firewall.
===
cd /etc/csf
sh uninstall.sh
===

Config Files
===
/etc/csf/csf.conf —CSF Firewall configuration file
/etc/csf/csf.allow —- Config file to allow IPs
/etc/csf/csf.deny —- Config file to deny IPs
/etc/csf/ —- Alert files with TXT extension are stored within this directory
===