Firewall

Firewall Configuration - macOS 11

To enable the firewall on macOS, you should do the following Open System Preferences On your Mac, click on the Apple icon in the top left hand corner of the screen Next, click on System Preferences Click on Security & Privacy Click Firewall If the padlock at the bottom left is locked, click it to unlock it Click on the ‘Turn On Firewall’ button Next click on the ‘Firewall Options’ button Next tick the box next to “Block all incoming connections” Click OK to apply that We’ll break this down, by turning on the Firewall we restricted the potential routes into our mac Then by blocking all incoming connections, we ensured that any attempt to access our machine will be blocked, choosing this option also enabled ‘Stealth Mode’. Stealth Mode prevents responses to some common network communication, so other machines looking for devices on the network won’t see you, it doesn’t make you invisible however, and properly monitored networks will still be aware of you, it just gives you a bit of extra anonymity on public WiFi.

Firewall Configuration - Ubuntu

So on Ubuntu, one of the first things you should do is enable the firewall, you can do that by entering the following command in Terminal sudo apt update && sudo apt install ufw && sudo ufw default deny incoming && sudo ufw default allow outgoing && sudo ufw enable and hit Enter, that should install Uncomplicated Firewall and configure it to deny incoming traffic and allow outgoing traffic So if we break that command down, we’ll go through exactly what is happening sudo apt update - downloads the package lists from the repositories and “updates” them to get information on the newest versions of packages and their dependencies. && - tells the computer to run the following command once the previous one is finished sudo apt install ufw - Installs the latest version of Uncomplicated Firewall from the Ubuntu repositories. sudo ufw default deny incoming - Tells Uncomplicated Firewall to deny incoming traffic by default sudo ufw default allow outgoing - Tells Uncomplicated Firewall to allow outgoing traffic by default sudo ufw enable - Switches on Uncomplicated Firewall and ensures that it starts every time the Operating System is booted.