The Linux Experiment Quick tips to improve Linux Security on your desktop, laptop, or server (hardening for beginners)
🎯 Загружено автоматически через бота:
🚫 Оригинал видео:
📺 Данное видео является собственностью канала The Linux Experiment. Оно представлено в нашем сообществе исключительно в информационных, научных, образовательных или культурных целях. Наше сообщество не утверждает никаких прав на данное видео. Пожалуйста, поддержите автора, посетив его оригинальный канал: @TheLinuxEXP.
✉️ Если у вас есть претензии к авторским правам на данное видео, пожалуйста, свяжитесь с нами по почте support@, и мы немедленно удалим его.
📃 Оригинальное описание:
Try out Proton Mail, the secure email that protects your privacy:
Grab a brand new laptop or desktop running Linux: #
👏 SUPPORT THE CHANNEL:
Get access to a weekly podcast, vote on the next topics I cover, and get your name in the credits:
YouTube: @thelinuxexp/join
Patreon:
Liberapay:
Or, you can donate whatever you want:
👕 GET TLE MERCH
Support the channel AND get cool new gear:
🎙️ LINUX AND OPEN SOURCE NEWS PODCAST:
Listen to the latest Linux and open source news, with more in depth coverage, and ad-free!
🏆 FOLLOW ME ELSEWHERE:
Website:
Mastodon: @thelinuxEXP
Pixelfed:
PeerTube:
Discord:
#Linux #security #cybersecurity
00:00 Intro
00:56 Sponsor: Proton Mail
02:32 Software and updates
04:04 Services and SSH
06:38 User management
10:10 Physical Security
11:35 SELinux, AppArmor, and firewall
14:04 Parting Thoughts
15:15 Sponsor: Get a PC made to run Linux
16:30 Support the channel
Password complexity tips:
Tips to secure SSH:
The more software you use, the larger the attack surface for your Linux install is. It’s always good to take a look at all the installed applications, and libraries, and remove what you don’t use anymore. You can also remove packages that aren’t linked to anything else and aren’t used by anything.
On Debian or Ubuntu, for example, you can find these by running sudo apt autoremove
And on a desktop, you probably already apply updates, or your distro has auto updates enabled. But on a server, it’s easy to let things slide, and forget to log in regularly and make sure things are up to date. I’m guilty of that myself.
And just like with packages, libraries, and apps, you should also make sure you only run the services you actually use. You can list all services running with:
systemctl list-unit-files
To stop a service you don’t need, you can run
systemctl stop SERVICE
To stop the service from starting with the system, you can run
systemctl disable SERVICE
If you’re on a server, the general rule of thumb is also NOT to run a graphical desktop on it. It will often be much more secure to use SSH to log in to the server remotely.
But you might also need to secure SSH first. If you have multiple users, make sure only the ones who need it have SSH access. To do that, you can edit the /etc/ssh/sshd_config file, and type AllowUsers then the names of the users that will actually have access to SSH.
Now, something that might be useful in general, for a server or a desktop, is making sure all the users are correctly handled. The first thing will be to disable root login.
If you decide to disable the root account, make sure at least one user has admin privileges though, or you’ll have a system without any way to access any task with sudo. Once you’re certain everything is ok, you can use the following method:
Edit /etc/passwd, and change the first line, by replacing /bin/bash, or whatever other shell root currently logs into, by /sbin/nologin (or /usr/sbin/nologin depending on the distro)
If you prefer, you can simply disable root login through SSH, so the account is still there if you want it locally, but remote attackers won’t be able to login as root. To do so, you can edit /etc/ssh/sshd_config, and uncomment the PermitRootLogin line, and then set its value to no. Restart SSH with sytemctl restart sshd, and you’re done.
To remove the ability to use USB, Thunderbolt or Firewire, you can add the following lines to their respective files (create them if need be). To revert this, just remove the lines that have been added in the various files by the commands.
Add: install usb-storage /bin/true to /etc/modprobe.d/
Add blacklist firewire-core to /etc/modprobe.d/
Add blacklist thunderbolt to /etc/modprobe.d/
8 views
0
0
2 months ago 00:00:15 1
IS-2 VS MAUS 🗿War Thunder #warthunder #warthundergameplay #warthundermemes #warthundertanks #shorts
2 months ago 00:01:36 1
Civilization 7 - Official Augustus Trailer
2 months ago 00:01:36 1
First Look: Augustus | Civilization VII
2 months ago 00:00:44 1
Artemis SLS Escape Basket Test
2 months ago 00:20:20 1
Install ROS2 Jazzy in Windows by Using WSL - Windows Subsystem for Linux
2 months ago 00:08:54 3
Linus Torvalds: Speaks on the Rust vs C Linux Divide
2 months ago 00:08:17 1
STEAM УНИЧТОЖИЛ СКАМЕРОВ, ЗАПРЕТ FACEIT АНТИЧИТА В COUNTER STRIKE 2?
2 months ago 01:28:32 1
Винда, Linux или macOS: какую ОС выбрать для программирования
2 months ago 00:01:01 1
Blood & Play - Official Trailer | Game Devs of Color Expo 2024
2 months ago 00:11:15 1
i was right.
2 months ago 00:01:16 1
Paper Perjury - Official Release Date Trailer
2 months ago 01:03:15 1
X-COM: UFO Defense 44 - Кидония или смерть [Финал].
2 months ago 00:02:42 1
I got SWAT’ed and handcuffed LIVE while Linux development streaming!
2 months ago 01:55:42 1
Civ Streams: The Antiquity Age | Civilization VII Developer Livestream
2 months ago 00:07:57 1
How to Setup a Path of Titans Server! - Step by Step Tutorial
2 months ago 00:01:14 1
The Green Book - Official Trailer | IndieMania Showcase 2024
2 months ago 00:00:55 1
Caves & Cliffs Update: Part I – Official Trailer
2 months ago 00:18:54 1
KDE’s goals, Apple & Google giant fines, Square Enix funds a Linux distro: Linux & Open Source News
2 months ago 00:28:01 1
DebLight OS | 32-bit/64-bit PCs | Lightweight | Based Indirectly on LMDE
2 months ago 00:03:42 27
Обновление сентября | Состояние разработки LoR l Переведено и озвучено на русский язык
2 months ago 00:02:01 1
Sid Meier’s Civilization VII - Gameplay Reveal Trailer
2 months ago 00:01:39 1
First Look: Hatshepsut | Civilization VII
2 months ago 00:17:31 1
Ubuntu LTS released • eol • Fifth & Final Point • Kernel 6.8 • Upgrade • Server, and Cloud