How to Install the Firewall UFW and GUFWsteemCreated with Sketch.

in #firewall15 days ago

How to Install UFW and GUFW on Ubuntu/Debian

Introduction

UFW (Uncomplicated Firewall) is a user-friendly front-end for managing iptables firewall rules. Its aim is to make managing firewall easier or, as the name says, uncomplicated. GUFW (Graphical Uncomplicated Firewall) is the GUI version of UFW, designed to make managing the firewall even easier for desktop users.

This guide will walk you through the installation and basic configuration of UFW and GUFW on a system running Ubuntu or Debian.

Prerequisites

  • A system running Ubuntu or Debian.
  • You should have superuser privileges or access to the sudo command.

Step 1: Installing UFW

UFW is likely pre-installed on most Ubuntu installations. However, if it is not installed on your system, you can install it by following these steps:

1. Update your package list

To make sure you install the latest version of the software:

sudo apt update

2. Install UFW

Using the package manager:

sudo apt install ufw

Step 2: Enabling and Configuring UFW

Once UFW is installed, it is disabled by default. Here’s how to enable and start using it:

  1. Enable UFW:
sudo ufw enable

This command will activate UFW and ensure it starts automatically at boot.

  1. Check UFW status

to see which rules are currently active:

sudo ufw status verbose
  1. Allow or deny specific services.

For example, to allow HTTP traffic on your web server:

sudo ufw allow http

Or, to allow traffic on a specific port, such as SSH (port 22):

sudo ufw allow 22/tcp

Step 3: Installing GUFW (Graphical Interface)

If you prefer a graphical interface, you can install GUFW. This tool makes it easier to manage firewall rules through a graphical user interface.

  1. Install GUFW
sudo apt install gufw
  1. Launch GUFW
    You can start GUFW from your application menu, or by running the following command in your terminal:
gufw

Step 4: Using GUFW

Once GUFW is launched, you can use it to manage your firewall settings:

  • Enable or disable the firewall with a single click.
  • Add or remove rules easily through the GUI.
  • Adjust settings for different profiles like Home, Public, or Office.

Conclusion

By following these steps, you should have successfully installed and configured both UFW and GUFW on your Ubuntu or Debian system. These tools will help you manage your system's firewall settings effectively and securely.

Remember to regularly check your firewall settings and update your rules as necessary to maintain security as your network needs evolve.

Coin Marketplace

STEEM 0.29
TRX 0.13
JST 0.033
BTC 63252.23
ETH 3035.50
USDT 1.00
SBD 3.73