Setting Up the Netfilter Firewall with iptables and ufw

  • Sander van Vugt


Most settings discussed so far involve security measures that make your server internally secure. You must also consider, however, that something or someone from the outside world will try to connect to your server, so you need some security at that level, too. The best way to achieve this security is with a firewall. If your server is connected to the Internet directly, you must have a firewall running on it. Netfilter, which is the default choice for all Linux distributions, is the firewall that is implemented in the Linux kernel. The iptables command gives you complete freedom to manipulate the Netfilter firewall. In day-to-day use, both names get confused frequently, but both refer to the same firewall. Ubuntu Server also offers a solution to make Netfilter administration easy: the uncomplicated firewall (ufw). In the second part of this chapter you’ll learn how to use ufw.


Network Interface Port Number Incoming Packet Destination Port Incoming Traffic 
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.


Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

Copyright information

© Sander van Vugt 2008

Authors and Affiliations

  • Sander van Vugt

There are no affiliations available

Personalised recommendations