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
3 weeks ago 00:38:31 4
322 Люди стали работать быстрее, но... — The Art Of Programming [ DevOps ]
3 weeks ago 01:22:40 819
[iXBT games] Sony купит FromSoftware / Катастрофа MSFS 2024 / Превью Avowed / Half-Life 3 быть / Эстонская тряска
3 weeks ago 01:22:40 31K
Sony купит FromSoftware / Катастрофа MSFS 2024 / Превью Avowed / Half-Life 3 быть / Эстонская тряска
3 weeks ago 00:06:48 11
[ExtremeCode] Уничтожаю Linux (снова)
3 weeks ago 00:13:54 5
How To Install Docker on Ubuntu LTS (Linux) (2024)
4 weeks ago 00:17:44 21
How To Install MySQL on Ubuntu LTS (Linux) (2024)
4 weeks ago 01:40:43 13
ОТВАЖНЫЕ ИСКАТЕЛИ Zoria: Age of Shattering
4 weeks ago 00:02:41 29
Royal the Serpent - Wasteland | Музыкальная визуализация – Аркейн, 2-ой сезон
4 weeks ago 00:02:35 15
Mick Wingert - Spin The Wheel | Музыкальная визуализация – Аркейн, 2-ой сезон
4 weeks ago 00:20:43 1
Google breakup, bcacheFS drama (again), Steam Controller 2 Linux & Open Source News
4 weeks ago 00:18:33 5
Google Chrome severely damaged extensions, time to move to a better browser
4 weeks ago 00:04:23 5
[VideoFromSpace] Huge NASA SLS Booster Put To Fire In Promontory, UT | Video
4 weeks ago 00:02:12 3
[Mercedes-Benz] David Coulthard and the SLS AMG E-Cell - Mercedes-Benz original
4 weeks ago 01:06:56 1
The Uncertain: Light At The End | Прохождение ➫ 04
4 weeks ago 00:03:46 12
[Mercedes-Benz] Mercedes-Benz TV: Questions about: SLS AMG Coupé Electric Drive – Part 1.
4 weeks ago 01:01:10 1
The Uncertain: Light At The End | Прохождение ➫ 03
4 weeks ago 00:46:23 1
The Uncertain: Light At The End | Прохождение ➫ 02
4 weeks ago 00:58:08 20
Josef Kadlec (Recruitment Academy .): Recruitment Engineering in the Transhuman Age / #HRAPI
4 weeks ago 00:58:08 11
[ENG] Josef Kadlec (Recruitment Academy): Recruitment Engineering in the Transhuman Age / #HRAPI
4 weeks ago 00:55:58 5
The Uncertain: Light At The End | Прохождение ➫ 01
1 month ago 00:45:42 13
[ZARGO] Полный Айсберг Linux: Что скрывается под поверхностью ОС?
1 month ago 00:02:32 134
#509 Малыш и Карлсон - 20 лет спустя - Приквел. - Скрытая фея.
1 month ago 11:54:58 21
[James Scholz] [ambient sounds] study with me live pomodoro 60min(1 hour)/10min
1 month ago 00:05:43 11
[David Bombal] Kali Linux NetHunter Android install in 5 minutes (rootless)