Install ConfigServer Security & Firewall (CSF) in RHEL,CentOS & Fedora

If You Appreciate What We Do Here On TecMint, You Should Consider:

  1. Stay Connected to: Twitter | Facebook | Google Plus
  2. Subscribe to our email updates: Sign Up Now
  3. Use our Linode referral link if you plan to buy VPS (it starts at only $10/month).
  4. Support us via PayPal donate - Make a Donation
  5. Support us by purchasing our premium books in PDF format.
  6. Support us by taking our online Linux courses

We are thankful for your never ending support.

Ravi Saive

I am Ravi Saive, creator of TecMint. A Computer Geek and Linux Guru who loves to share tricks and tips on Internet. Most Of My Servers runs on Open Source Platform called Linux. Follow Me: Twitter, Facebook and Google+

Your name can also be listed here. Got a tip? Submit it here to become an TecMint author.

Receive Your Free Complimentary eBook NOW! -

Download Free Linux eBooks

Linux BASH Programming Cookbook
Getting Started with Ubuntu 16.04
A Newbie's Getting Started Guide to Linux
Introduction to Linux - A Hands on Guide

You may also like...

17 Responses

  1. vijay says:

    how to block webmail upload attachments in firewall . plz help . i donot want my users uploding files to internet. https gmail uploads i want block . plz help .

  2. me says:

    CSF is NOT open source!

  3. Muhammad Sohail says:

    Kindly give me some suggestions regarding my problem. I ll be thankful.

    • Ravi Saive says:

      Sorry for delay in replaying, you need to define your network range to enable access to your server.

      • Muhammad Sohail says:

        kindly explain it a bit. How can I define network range. As a webserver the server is going to be accessed from all over the world. So, I think it would be impossible for me to define any range.

        If I am wrong, Kindly correct me.

        • Ravi Saive says:

          Please add the ports that you want to accessible from public to the below line.

          # Allow incoming TCP ports
          TCP_IN = “20,21,22,25,53,80,110,143,443,465,587,993,995”

          • Muhammad Sohail says:

            These ports have already been added. But still not working.

            Anyways thanks alot for your response.

  4. Muhammad Sohail says:

    First of all I would like to congratulate you on running such a brilliant web site. I have never come across such a useful website.

    Kindly help me regarding one of my problems using csf:

    In csf.allow I have added (for allow all)

    When I remove this line my server becomes inaccessible. When I enable it any ip address is allowed whether it is suspicious or not.


  5. nabeil says:

    [root@localhost /]# rpm –import public.gpg.key
    error: public.gpg.key: key 1 import failed.
    [root@localhost /]# rpm –import public.gpg.key
    error: public.gpg.key: key 1 import failed.
    [root@localhost /]# yum install webmin
    Loaded plugins: fastestmirror
    Loading mirror speeds from cached hostfile
    * base:
    * extras:
    * updates:
    Setting up Install Process
    No package webmin available.
    Error: Nothing to do

  6. Golden Owl says:

    So thanks for CSF post.I hope next nice posts also. :)

  7. Florian says:


    I have install ZPanel with your configuration but after, i can’t use mail. How i must configure CSF, Fail2ban and rkhunter with Roundcube 0.8.1 ?

    Thanks to your help !


  8. svisen says:

    Hi All,

    Can any one guide me how can i configure CSF for preventing the Brute force attack on the servers.

    I have installed CSF on centos5.8 64 bit and accessing it through the webmin.

    Please assist as completely new to the firewall thing.


    • Ravi Saive says:


      We will soon provide you how to integrate CSF with Webmin in our upcoming article.

      • svisen says:

        Hi can u please guide me how to configure the CSF to prevent the RDP brute force on my windows servers.

        I cannot add or restrict the Ip range as my client has requirement to access it it from any where i just want to prevent the Brute force attack happening on my servers so that if any ip makes request to frequent it block it up.

        need assistance ….

  9. how about Debian based?

Got something to say? Join the discussion.

Your email address will not be published. Required fields are marked *

Join Over 300K+ Linux Users
  1. 177,942
  2. 8,310
  3. 37,548

Are you subscribed?