The majority of the web hosting in the current days is running on a Linux VPS server. At this point, it is general knowledge that a firewall is the most basic yet one of the important defence mechanisms needed in a VPS. A firewall checks the request exchanged from the outside with the VPS and filter off ones that seems malicious. The following lists are some of the well-known firewalls used on Linux servers. Do note that the index doesn’t determine the ranking of the firewall.
1. Iptables
Starting with Iptables, Iptables is a common Linux firewall that had been intergrated into most of the Linux OS by default. This firewall is still a powerful solution for filtering traffic for Linux OS since some time ago. The fact that this firewall is lightweight makes it even more favorable for Linux users due to it being able to provide a good firewall while minimizing performance loss.
Iptables is currently considered one of the most flexible firewalls after evolving much more from the past few years. It also provides features such as backup and restore support, and also being able to work on varieties of levels. The only downside of this firewall is the user-friendliness, due to the lack of GUI (Graphical User Interface), and can only be worked with command lines, which some users may not be able to work with.
2. Nftables
The next Linux firewall is the Nftables, This firewall is built by the same team who built iptables and it is expected that Nftables would be the successor of iptables soon. Similar to iptables, this firewall can only be configured using command lines. However, it does provide a more readable syntax compared to iptables.
This firewall also comes withe the feature that support IPv4 and IPv6. Only a few Linux operating systems had intergrated nftables such as CentOS 8. It would allow server users to easily set up the firewall if it is intergrated into the operating system. It is recommended for Linux user that prefers a built-in firewall to start familiarizing themselves with nftables as it is expected to be a Linux firewall in the near future.
3. UFW
UFW, which stands for Uncomplicated Firewall, is another firewall solution for Ubuntu OS. It is still possible to install it in any Linux distribution despite not being found in all software repositories. This firewall is currently only integrated into modern versions of the Ubuntu operating system.
This firewall provides a GUI which allows users to easily configure it. Aside from that, this firewall also provides multiple features such as the ability to block a certain range of IP addresses, IPv6 support as well as limiting access to certain ports.
4. CSF
CSF, or ConfigServer Firewall, is another commonly used firewall for Linux servers. The reason for its fame is due to it being open-source, and also the fact that is uses iptables as a framework, which allows configuring the setting on Linux more conveniently.
CSF also provides a good number of features, such as port scanning and protecting against SYN floods. One of the impressive features it has is the Login Failure Daemon. This feature checks for brute-force attempts often and blocks the IP that seems suspicious.
Despite all the nice features, the strong suit of CSF is actually being integrated into popular control panels used for web hosting such as cPanel/WHM, Direct Admin, and so on. This allows users to configure CSF without the command-line interface. The GUI plugins of CSF are also able to show detailed statistics and conclusions regarding the possible attack patterns.
5. pfSense
PfSense isn’t a dedicated firewall system, but actually a powerful routing platform. However, it can also be used as a DHCP, firewall, DNS server as well as its main usage, as a router.
Despite being used as multiple tools, it still provides multiple features such as protocols and ports, real-time information feed regarding the server, WAP and VPN endpoint functionalities, and more. PfSense also allows users to set multiple preset rule profiles and a per-interface configuration, which allows more flexibility in the system.
6. Shorewall
Shorewall is another open-source firewall for Linux OS. This firewall is able to track connections and filter packets by using the Netfilter framework. There are several more features that are available in Shorewall firewalls such as VPN support, traffic shaping and accounting, blacklisting individual IPs and subnetworks, and more. This firewall also provides a GUI and can be integrated into the Webmin control panel.