The second line of defense after a good firewall is good computer security. Linux isn't like Windows, you don't just download a Anti-Virus/Firewall and away you go. You have to do a little bit of work, but in turn you can learn alot.
The list below of security items was written mostly for Raspberry Pi's and desktop/laptops running Raspbian but should work for any type of Linux.
First thing to always do is change the default password. NEVER HAVE A WEAK OR DEFAULT PASSWORD.
One of the first things you always do it make sure your computer is up to date.
This is a little script I use to do that.
Configure the SSH Server.
SSH is stands for Secure Shell and it is used everywhere. They protocol encrypts your terminal window traffic and alot of other stuff if you route it through ssh.
Comment out the whole file of /etc/ssh/sshd_config to use as a template for later and add the following to the bottom:
Configure the SSH Client.
/etc/ssh/ssh_config
Here we add and get rid of the old ciphers and MACs.
Append the /etc/security/limits.conf with the following:
Append the /etc/sysctl.conf with the following:
Firewalls helps to prevent just anyone from connected to your computer. I'm going to share a bash script you can use to configure a firewall. Use it as a template, all networks are different and what you want to do should be different everywhere.
Remember firewall rules flow from top to bottom. If you allow it to go through before a global deny then it will be allowed.
I highly recommend my block list. I prefer the deny all incoming and allow outgoing, keeps the bad guys at bay more.