The door to safety swings on the hinges of common sense
The Internet is a dangerous place if you don’t know how to navigate correctly or don’t take proper precautions. A firewall is a program that acts as a protective barrier, a gatekeeper or a security guard between you and the Internet. In other words, it prevents unauthorized Internet traffic from entering or leaving your computer, both by software programs and users.
Windows Defender is a decent firewall and antivirus inbuilt in Windows operating system that can be enough for most users.
If you don’t have any other firewall running, you should turn on the Windows Defender’s firewall by navigating through Settings, Privacy & Security, Windows Security, Firewall & network protection. If the firewall is off, you will see a red x icon, click the Turn on button to turn on the firewall. The red x icon will turn into a green check.
Windows Firewall
The best free firewalls are:
Apple integrates within macOS a firewall that controls all incoming and outgoing connections to your Mac.
It comes disabled by default, but should be enabled whenever possible. To turn on the Firewall, go to System Preferences, Security & Privacy, Firewall, and smash the Turn On Firewall button.
macOS Firewall
Then, click Firewall Options to fine-tune the firewall settings, Enable Automatically allow built-in/downloaded signed software to receive incoming connections (it adds stock apps -iTunes, Mail, Messages- and downloaded apps that are signed by a valid certificate authority to the list of allowed apps) and stealth mode (it prevents your macOS from responding to probing requests or queries to reveal its existence from the network).
macOS Firewall
Firewalld is a firewall that uses nftables by default. This brief tutorial shows you how to install and configure it in Arch, GNU/Linux.
# Install necessary packages
sudo pacman -S firewalld ipset ebtables
# Enable and start firewalld.service.
sudo systemctl enable --now firewalld.service
# Change the default zone to home.
sudo firewall-cmd --set-default-zone=home
# Open ftp, htpp, samba, and synchthing services: --permanent because changes made in Runtime configuration are lost when the firewalld service is restarted.
sudo firewall-cmd --add-service=ftp --permanent
sudo firewall-cmd --add-service=http --permanent
sudo firewall-cmd --add-service=samba --permanent
sudo firewall-cmd --zone=home --add-service=syncthing --permanent
# Allow traffic on an incoming port (24800) -Barrier-
sudo firewall-cmd --add-port=24800/tcp --permanent
# Restart the firewall.
sudo firewall-cmd --reload
# List allowed service and ports on the system
sudo firewall-cmd --list-service
dhcpv6-client fttp http mdns samba samba-client ssh syncthing
Ufw stands for the uncomplicated firewall