You have a firewall, though it is not enabled by default (it is built into the Linux kernel). To understand why it isn't enabled by default, have a look here:
viewtopic.php?f=29&t=103992#p599112You can either activate and configure it from the terminal, or you can install a graphical front-end. To activate and configure it from the terminal you would use ufw. To enable it and disallow incoming connections by default (another machine trying to reach your machine, while you have not requested anything from that machine), you would run:
- Code: Select all
sudo ufw enable
sudo ufw default deny
Anyway, probably you will find the graphical front-end for that easier. As shared above, you can install gufw for this. Open Software Manager and search for "gufw", install it. After installation you will find it as Firewall Configuration in the System section of the menu. Click the Unlock button to make changes, then drag the OFF button to ON. Close the application. Remember that this is just the configuration front-end, so you don't need to run this for your firewall to be active. To allow other machines to connect to your machine, you would go to the Edit menu and add a rule to allow certain services on your machine to be reached by others. Note that depending on how you connect to the Internet, you will also have to enable your machine to be reachable from the Internet in your broadband modem's configuration.
With the changes done here, or with the commands above, your firewall will be active upon each boot.