Configuration of the UFW firewall on Ubuntu 22.04
The following guide describes how to install UFW Firewall on Ubuntu 20.04. Everything is done with a few clicks in the console.
At the beginning we update the packages
1 | sudo apt update |
We install UFW
1 | sudo apt install ufw |
The service status can be checked by issuing a command:
1 | udo ufw status verbose |
Score:
1 | Status: inactive |
We will launch the UFW with the help of a command:
1 | sudo ufw enable |
We can also install a graphical firewall management package, the whole thing can be done by issuing a command
1 | sudo apt install gufw |
To unblock a given port or service we issue a command:
1 | sudo ufw allow NAZWAUSŁUGI |
Here are some examples:
SSH:
1 | sudo ufw allow ssh |
Http
1 | sudo ufw allow http |
You can also allow access for a given port along with the protocol. An example below:
1 | sudo ufw allow 80/tcp |
Related entries:
ack -l DB_NAME
wp-config.php
wp-admin/setup-config.php
wp-config-sample.php
wp-content/plugins/litespeed-cache/src/db-optm.cls.php
wp-content/plugins/newsletter/system/status.php
wp-includes/load.php
wp-includes/ms-load.php
2 php versions on CentOS 8 z Apache i PHP-FPM
Monitoring the server with Munin in Debian 10
Installing Opcache in Ubuntu 20.04 for Apache and Nginx
Screen, that is, the virtual consoles in Debian systems and Centos