Published
danyal.dk
Published
Related Posts
-
Ubuntu 18.04 LTS: What’s New?
Published
-
Generate freeSSL Let’s Encrypt – Per Domain – 1/3
Published
-
Generate free SSL Let’s Encrypt – Wildcard Certificate – 2/3
Published
-
Resolved: forced HTTPS redirect in Homestead running Laravel app
Published
-
Laravel composer install – Your requirements could not be resolved to an installable set of packages.
Published
Basic Firewall on Ubuntu Server
UFW can be used to set up firewall on Ubuntu server, that make sure only connections to certain services are allowed.
With UFW we can register different application profiles upon installation. These profile allow UFW to manage these applications by name.
OpenSSH is most commonly used application used to access server shell.
Registered profiles can be listed by running following command.
# ufw app list
Output
Available applications:
OpenSSH
In order to access server shell, we need to allow SSH connections. SSH can be allow by running following command.
# ufw allow OpenSSH
Once OpenSSH is allowed, now let’s enable the firewall.
# ufw enable
Type “y” and press ENTER to proceed. You can see that SSH connections are still allowed by typing:
# ufw status
Output
Status: active
To Action From
-- ------ ----
OpenSSH ALLOW Anywhere
OpenSSH (v6) ALLOW Anywhere (v6)
At the moment firewall blocks all the connections expect SSH, if you need to install and configure other services; remember to adjust firewall accordingly. For additional help take a look at "UFW Essentials" well written article by Mitchell Anicas at DigitalOcean community.