在本文中,我们将学习–如何在Ubuntu 16.04上配置和设置UFW(防火墙),UFW代表“不复杂的防火墙”,它充当IPTABLES的接口,从而简化了防火墙的配置过程,对于防火墙来说,这是非常困难的。初学者学习和配置防火墙规则,在这些规则中,我们将保护计算机免受未知用户的访问。UFW使用我们配置为规则的策略。
先决条件为此,我们需要在计算机上具有root权限的非root用户。
安装UFW(防火墙)
UFW默认情况下随Ubuntu一起安装,如果未安装,则我们将使用以下命令进行安装–$ sudo apt-get install ufw -y
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following NEW packages will be installed:
ufw
0 upgraded, 1 newly installed, 0 to remove and 88 not upgraded.
Need to get 149 kB of archives.
After this operation, 838 kB of additional disk space will be used.
Get:1 http://in.archive.ubuntu.com/ubuntu xenial/main amd64 ufw all 0.35-0ubuntu2 [149 kB]
Fetched 149 kB in 0s (165 kB/s)
Preconfiguring packages ...
Selecting previously unsel