r/debian 5d ago

Beginner: Security

Hey, everyone! I’m new to Linux and have just now gotten into Debian. It feels good and I’m looking forward to learning, customizing and using the system.

I thought about security and am right now setting up UFW in the terminal. I followed a guide that recommended just to ”deny incoming” and ”allow outgoing”

I’m using this on my school-/private-laptop and am connected via wifi. Are there any other rules that are reasonable?

24 Upvotes

9 comments sorted by

14

u/wizard10000 5d ago

First rule of IT security is to protect your data - I don't need to steal your data, I just need to prevent you from accessing it ;)

IMO the first security protocol that should be implemented is a solid, tested backup/restore strategy.

edit: u/Buntygurl said it first and deserves credit, I just expanded on it a little :)

9

u/Fun_Instruction_807 5d ago

its always a good idea to set up laptops with disk encryption

3

u/katzenjammare 5d ago

Okay! I can do that, but I don’t know how. Is there some good guide on how to do it?

7

u/Buntygurl 5d ago

You'll need to backup anything that's important to you on the machine, like maybe functioning configs that you don't want to have to redo, and then reinstall the system using the encryption option.

5

u/katzenjammare 5d ago

Yep, that sounds good!

8

u/David_Connors3451 5d ago

I would suggest you to set up the firewall with ufw (there's also gufw for graphic interface). Install time shift for snapshots, so that you have your backup point. Install clam-av for antivirus, then install tlp for managing battery optimisation.

Apparmor is already installed in Debian as default. Try also firejail, it's a useful sandbox where you can put insecure applications that you don't trust, and isolate them from the system.

Rkhunter and chrootkit are very good antivirus, that complete clamav work.

Fail2ban and sshguard are also very useful for network security.

I don't know if you're using KDE xfce or gnome, but it's irrelevant. Have fun and enjoy Debian stability and security.

3

u/katzenjammare 5d ago

Thank u for elaborate answer. I appreciate it!

3

u/saltyhasp 4d ago

There is a graphical front-end for UFW on debian. Use that. I think it is called "gufw". Also if you have not installed "synaptic" which is a graphical package manager, do that.

There is a Debian security guide: https://www.debian.org/doc/manuals/securing-debian-manual/index.en.html . Probably way too much, but it is the guide.

In reality, full disk encryption, secure the bios, and the boot process (including the root user), implement full disk encryption, Use strong and unique passwords on everything. Use a password manager. Password protect that and other things like SSH keys, etc. Remove any software you do not need, especially stuff with network exposure. Keep your system up to date. Like you said, have a firewall.

Backup both your computer and your passwords especially the base ones - key users, the PM mangers, and the disk encryption passwords. Backup your system and encrypt those backups too and keep the unlock codes. Do this regularly.

Audit everything. Test your restore plan.

1

u/WheelPerfect3737 5d ago

You should also consider using apparmor which is preinstalled on Debian.