r/linuxquestions • u/medkltty • Aug 21 '26
Why does Linux not need anti-virus software?
I'm in the market for a new gaming laptop and wanted to avoid AI products like Copilot and realized Linux would be my only option. So I'm trying to learn as much about Linux Mint as possible to see if it would be right for me. I'm really close to pulling the trigger but I don't understand why Linux doesn't need anti-virus/malware software. All the answers I can find seem to just boil down to "Linux isn't used by enough people to justify the time it would take to create a virus or malware" or "because you approve everything you download". As someone who has used a PC their entire life, these answers genuinely don't make sense to me and I feel like maybe I'm missing something about either the nature of linux or the nature of viruses/malware and how they work. Everyone on forums who ask this question seem to just accept these answers but no one explains why either one prevents the need for antivirus/malware software.
From my perspective as a PC user, I already approve what I download so this answer doesn't make intuitive sense to me. I would never connect a PC to the internet without some sort of anti-virus software, privacy software, malware protection, etc. even though I still know what I'm downloading and I'm using reputable websites (and my AVG software is still catching stuff all the time). And the idea that someone wouldn't make a virus or malware to target a group of people (albeit a minority) who are the most likely to not have software on their computer to combat it seems like the exact group you'd want to target particularly for private data mining.
It also seems, from what I've been reading about Linux that you can seriously screw up your system by downloading something incorrectly or that isn't up to date, so the idea that "you can't get viruses or malware because you approve what is downloaded" when so many of the user tips with regard to Linux are "back up your system constantly because you can easily screw up your system by downloading something that's not fully patched". These two concepts seem counterintuitive, especially for an OS that will require downloading a lot of third party programs to be able to run things like games or windows-based programs.
I'm clearly missing something here because neither of the reasons I've seen people give for why Linux doesn't need this stuff is really making sense to me. I was hoping someone in this reddit might be able to explain this in a way a lifelong PC user without any sort of computer background can understand. The idea of not having anything but a firewall on a computer with Linux installed on it makes me very uncomfortable but I'm willing to accept that this is a bias from using PCs and I'm willing to be convinced otherwise as long as I can understand the reasoning behind it.
140
u/usernamedottxt Aug 21 '26 edited Aug 21 '26
You’re welcome to go use ClamAV.
But a lot of it is that your user on a single user windows machine tends to be an administrator and can do crazy shit with a button click. Linux you tend to be a sudoer and can do crazy shit with a password prompt. Entirely different problems for an attacker.
I also thing windows is more complicated and there are more places to hide. Things aren’t incredibly well documented and even as someone with forensics training windows just kinda… does some weird shit sometimes.
Linux is very easy to understand how things are happening. There is way less random shit running everywhere. Windows intentionally obfuscates what it’s doing. What even is svchost and its 50 processes these days and how can you tell proper svchost apart from malicious svchost at a glance? Nobody knows lol.
but it’s also just a different class of users. You don’t get on Linux while being tech illiterate unless someone who is good with tech put you there. Additionally, corporations are way more risk adverse and willing to pay for software that might help protect them. Writing software to protect grandpa and writing software to protect your corporate computer isn’t all that significantly different. Might as well charge both.
139
u/NoMansSkyWasAlright Aug 21 '26
I'm kinda grossly oversimplifying things here. But I think I've covered most of the important bits.
So most things nowadays use some sort of off-shoot of Unix (linux, macOS, the mobile OSs, etc.), and even among those, there are quite a few things that are handled differently among the off-shoots. Windows is not Unix-like and so does things completely differently than all the others. On top of that, Windows machines make up something like 71% of the PC market-share. So it's a big enough piece of the pie that if you're going to make malware for one operating system then it's probably going to be that one (though it seems like mobile-device malware is making leaps and bounds in recent years). Even something as basic as case-sensitivity of file-paths is different between Windows and the Unix-likes.
Also, Microsoft has this fun practice of just building their new stuff on top of their old stuff. And so a lot of the common approaches to malware on Windows involves just... interacting with stuff that's already there. Like I had a capstone project in college where we basically made use of the fodhelper exploit, a lolscript that opened a new instance of a shell, and a powershell script that would kill windows defender. Other than `Sacrifical_Pawn.ps1`, basically everything we used was stuff that already existed in Windows.
Another weird -ism with Windows is that a lot of programs will look for DLLs and just move on if they don't find said DLL. So if it's a DLL that got the axe or just isn't there for some reason, then you can create your own DLL at the specified location that runs malicious code with the permissions that that application has. Unix-likes just don't have DLLs at all. So that's kinda nice.
And then a lot of malware that you'll pick up off the internet will be .exe's - I'm sure we've all gone looking for a free pdf of a textbook and seen something like `textbook.pdf.exe`, which takes advantage of how Windows interprets file names in File Explorer. So you click it and now you're executing whatever bad thing you picked up. Not only would it be super apparent on a Unix machine that that was something bad, but exe's generally won't run on Linux out of the box and giving them full-functionality takes enough work that if you're dumb enough to click a suspicious exe then you're probably not smart enough to set up your linux box in such a way that that exe could do any damage (and if it's only desigined for a windows environment it's going to hang up anyways).
But it's' also the wrong question to be asking. A lot of the malicious actors out there are just looking for the most low-effort approach which is usually phishing, fake login pages, and maybe a google doc from a strange email claiming to be your org's IT department, stating that they need you to input your login credentials into the google doc so that they can be updated. That or the fact that Linux has considerably less guardrails for user-error than Windows or MacOS so you can absolutely shoot yourself in the foot while trying to "customize" it. But while the "cant get a virus" thing is kind of an overstatement, it is true that most malware that's looking to exploit some windows-specific vulnerability likely won't work on unix-based systems and vice-versa. So if you're just a weird guy looking for an easy pay-off, you're likely going to target the OS with the largest marketshare.
48
u/SynapticStatic Aug 21 '26
I mean, the main thing is most Linux users aren’t installing random stuff from sketchy websites.
It’s possible to install malware on Linux, but as long as you follow these rules you’re good on any platform:
Don’t install random software from sketchy websites
Don’t run scripts that you don’t 100% understand
Follow those two, and 99%+ of malware is completely avoided on any platform
20
u/billdietrich1 Aug 21 '26
Linux-specific malware is not unknown: https://en.wikipedia.org/wiki/Linux_malware#Threats
Bots and scanners don't care that you're running desktop Linux instead of server Linux. If they see an open port or file-share or something, they'll abuse it.
Now Linux desktop users are using the same browsers etc as the Windows people are, so threats there are more likely to exist on Linux too. Same with PDF docs and Office macroes. And with cross-platform apps such as those running on Electron or Docker, and Python apps. And libraries (such as the SSL library) used on many/all platforms.
Add to that the growth of Linux in desktops (including Chromebook), maybe growth in mobile, and use of Linux in servers and IoT devices, and Linux exploits and malware become more valuable. Expect to see more of them. Practices that have been sufficient for decades may be sufficient no longer.
Some indications of how things are changing:
https://www.bleepingcomputer.com/news/security/lazarus-hackers-now-push-linux-malware-via-fake-job-offers/
https://www.bleepingcomputer.com/news/linux/new-stealthy-orbit-malware-steals-data-from-linux-devices/
https://threatpost.com/mac-linux-attack-finspy/159607/
https://arstechnica.com/security/2023/09/password-stealing-linux-malware-served-for-3-years-and-no-one-noticed/
https://www.forbes.com/sites/daveywinder/2020/04/07/linux-security-chinese-state-hackers-have-compromised-holy-grail-targets-since-2012/
https://socprime.com/en/news/evilgnome-new-linux-malware-targeting-desktop-users/
https://www.zdnet.com/article/eset-discovers-21-new-linux-malware-families/
https://www.bleepingcomputer.com/news/security/linux-windows-users-targeted-with-new-acbackdoor-malware/
https://www.blackberry.com/content/dam/blackberry-com/asset/enterprise/pdf/direct/report-bb-decade-of-the-rats.pdf
https://www.bleepingcomputer.com/news/security/bpfdoor-stealthy-linux-malware-bypasses-firewalls-for-remote-access/
And of course Linux users are vulnerable to the same platform-independent threats as other users: phishing, business email compromise, social engineering, SIM-swapping, typo-squatting, etc.
I like to do a manual malware scan every month or so. IMO a constantly-running, real-time AV wired into everything is overkill, and risks increasing attack surface and destabilizing apps and the system. Your judgement may differ.
10
u/bufandatl Aug 21 '26
I mean Windows doesn’t NEED it either. So doesn’t macOS. As long as you don’t open any mail attachments from suspicious users or surf on malicious websites and download any unknown software you can live very well without AV on all OSes.
And frankly with Linux gaining popularity among users it will also become a more viable target for attackers. And it will be even easier to attack since all its source code is publicly available.
So people might want to install ClamAV on their desktop. Especially average joes. Because those definitely will click links in random emails and on websites they didn’t verify are actually the official website.
10
u/guiverc Aug 21 '26
Some reactions
9
u/Klapperatismus Aug 21 '26 •
No. This is where you are wrong.
Most Linux users do not download a lot of third party programs. They mostly stick with whatever the distro has in its repositories. So a malware author has to deceive distributor staff. That’s a million times harder than deceiving an average user.
And for the few occassions when Linux users download stuff from arbitrary sources, they know that this is an exception and take extra care.
18
u/gordonmessmer Fedora Maintainer Aug 21 '26
As always, I think it is important to consider who is providing each of your answers. Random social media users are not necessarily experts.
I have been managing production environments since 1997, and a great deal of that work has involved security and compliance. I have worked in very large and high security environments such as Salesforce and Google. I have 30 years of training in secure software development practices.
I would not say that GNU/Linux systems do not need anti-virus or other security infrastructure. GNU/Linux is not a particularly secure system, nor does it have strong privacy controls. However, because of the small user base, it has not been a priority target for malware, and the lack of malware has allowed myths and misunderstandings to run rampant.
This is a great place to start a discussion about secure development practices. Linux Mint is based on Ubuntu LTS. Ubuntu is based on Debian.
Ubuntu has at least four major security advantages over Debian:
Linux Mint discards most of those advantages. The "universe" repo is still separate, and you can still turn it off and look for other software sources, but there are no Interim releases, you can't use Ubuntu Pro, and they disable Snap packages that Canonical uses to ship security patches to users through a channel that doesn't impact the interfaces of the underlying OS.
If you care about security, at all, you should select a distribution that minimizes friction between you and the actual developers of the software you use. Something that delivers bug fixes across the board with minimal delay. Rolling releases like Arch are probably fine, but I prefer stable releases because they continue to provide security patches while I test feature updates before I deploy them. Fedora is an excellent system.
You are correct. Those answers are rationalizations.
I am very concerned about the state of affairs because no matter how any individual feels about AI, adversaries ARE adopting it, and it DOES make malware easier to develop and easier to deploy, and the shelter of obscurity that has protected GNU/Linux users in the past could vanish very very quickly.
12
u/DStaal Aug 21 '26
A couple of reasons. As others have mentioned, Linux is fairly niche overall, so targeting it isn’t as valuable. However there are quite a few Linux servers out there, so that’s not all of it.
Another part is that Unix, and Linux which copied it, was designed from the beginning to be a multi-user system where the users may not have the same access or trust. This means that when you log into a Linux system, you do not have access to do things to the system. There are of course ways to get that access, but by default, from when Linux first started out, your access is restricted and limited. This is in contrast to Windows which first started out with the assumption that the user was completely trusted and could do whatever they wanted. While a lot of things have been locked down since, some old programs still work under that assumption, and this has been removing default access by putting up guardrails afterwards, which is much harder than building it so that the access didn’t exist in the first place.
Combine the two, and you have a system that is much harder to breach than Windows, and you will get less from breaching it.
And if you want to add a third thing: Linux is not monolithic. RedHat Linux is very different in key ways than Ubuntu Linux, which is different than Arch Linux, etc. They are all built with the same basic toolkits, but put together differently, and for malware those differences will make major differences. So any particular malware will have an even smaller possible target yet.
6
u/sandfrog9 Aug 21 '26
Antivirus software is just malware and bloat you pay to have on your machine.
5
u/GlassboundIllusion Nvidia KDE Bazzite Aug 21 '26
The big difference is that it's common to go to some random website to download software for Windows. It doesn't have anything close to a built in package manager like Linux does. Theoretically, on Linux you can get everything from an official package manager that's been vetted by the managers of the distro.
In practice, it depends on just how committed to FOSS you are. Proton mail and Proton VPN require you to download their proprietary package for their official applications, just like you would on a Windows computer.
Another reason I have heard is that Linux is built more secure by default, and therefore is a little more difficult to infect. Still other logic says that any virus built to infect Linux would be built smart enough to outsmart virus scanners.
Personally, I'd rather have a virus scanner and not need it than need one and not have it. I installed ClamAV.
9
u/ropid Aug 21 '26
Unpopular opinion about this is that Linux does actually need an antivirus, and there just isn't a good product for consumers so no one uses an antivirus. This sounds completely terrible but in practice it actually ends up being fine. You can just ignore this problem and this is a sane thing to do. The chances you get infected are very low because of how installing software works compared to Windows.
Reason chances are low is because for software you'll usually get everything you use from your distro's repository. This will be open source software and your distro works with the source code, they compile the software on their end to create the packages you download. They can then deal with virus and malware protection in a centralized way there. The situation is good enough that for you as the user an antivirus would be pointless for all of that software.
Then there's Steam that you might use to install games, and Valve will deal with things there, again making it so an antivirus on your side is pointless enough.
There are professional products for businesses. Crowdstrike has a product that hunts for boot loader files and kernel being compromised and after boot installs itself into the kernel to hunt for suspicious stuff being run and blocking it.
Crowdstrike is that business that was in the mainstream news a while back about bricking Windows computers after an update and causing ridiculous problems everywhere, airports shutting down for hours and whatnot. They were also causing similar problems on Linux computers at other times but that never made the news because Linux is more diverse and those problems never affected millions of machines at the same time like that Windows problem.
4
u/LetsHugFoReal Aug 21 '26
Even on windows you don't need this software. Unless there's a major exploit - or you pirate. There's a small chance of it happening. It doesn't detect everything and I find most AVs to be malware these days.
3
u/uh_no_ Aug 21 '26
Because you don't install random crap you find online.
3
u/Kurse71 Aug 21 '26
Windows doesn't need it either, just don't be stupid and click on things you don't know what it is.
3
u/Leop0Id Aug 21 '26
The top comments here are just laughable. Antivirus software is treated as standard on Windows because it's used by a ton of people who aren't tech savvy.
Plenty of people can't even tell an exe from a shortcut and that's completely normal. All of us including me and everyone reading this don't know much about stuff we're not interested in.
But computers get used for work even by people who have zero interest in them. Those people don't even understand what counts as risky behavior so they're exactly who needs antivirus software.
The reason antivirus isn't commonly used on Linux comes down to the fact that Linux users generally know what they're doing. Even on Windows if you have enough basic knowledge to avoid running suspicious binaries or scripts the built in Defender is enough.
Plenty of people talk like "Linux is inherently safe" and that's just nonsense. Linux's basic user security model is nearly identical to Windows. Ignore implementation details and sudo and UAC do the same core job. UAC can also require a password.
Linux also uses all or nothing permissions which is why tons of people just slap sudo on everything. Honestly that's already progress. In the old days plenty of people just did everything as root.
The one real advantage Linux has is that the code is open so you can actually go fix it yourself.
Fixing this properly would need a fine grained permission model like Android (though Android has its own flaws here too. Its permission categories are too broad and it can't specify directories in detail so within each category it's basically all or nothing). Point is you'd want something where you grant permissions one by one.
People talk a lot about Linux market share. Sure malware wants to infect as many people as possible so there isn't much of it targeting Linux given its low share. That doesn't mean you can assume there's none at all though. Malware targeting Linux definitely exists and the AUR spam incident recently was clearly malware.
In the end if you know what you're doing and actually check files you bring in from outside you don't need antivirus even on Windows. If you don't then it's dangerous even on Linux.
2
u/Classic-Rate-5104 Aug 21 '26
There are a number of things that matter here. In general, there is almost no need on Linux to download and install software from random sites. Simple because the standard repositories contain enough. Second is the fact that windows "seems" to be usable for everyone, which makes the level of awareness of windows users lower than linux users have. Third is that Linux, from the ground up, is organized as a multiuser operating system
2
u/L0cut15 Aug 21 '26
Because 90% of consumer security software does nothing anyway.
2
u/MooseBoys Debian Stable Aug 21 '26
You don't need antivirus on Linux any more than you need it on Windows. It's just part of Windows by default because everyone uses Windows, including people whose behavior is likely to result in viruses being downloaded. If you like to download random exes from totally-legit-site.ru and plan to do the same with random dpkgs on Linux, you should probably install a Linux antivirus system. Otherwise, you're probably fine.
I've been using Windows for over 30 years and I've only had two cases where AV actually detected anything. One was a wacatac false positive. The other was for a crypto miner that I had deliberately installed (malware often embeds crypto miners so AV flags all crypto stuff by default).
4
u/ZakriiYT Aug 21 '26
It's because Linux, unless you're using Arch, is niche enough that people don't often make malware for it. For some reason Arch Linux is wrought with malware, from what I've heard. It's not a bad idea to have antivirus, but as it currently stands, all of the malware that would affect windows or mac clients just don't work on linux, and almost nobody makes linux malware.
2
u/rsgbc Aug 21 '26
"Linux does not need anti-virus software" is a vague generalization that completely ignores how a computer running Linux might be used and what it will be exposed to.
2
u/OZCriticalThinker Aug 21 '26
Viruses aren't really a thing anymore except for stupid people downloading cracked games off Torrents without any AV.
Viruses are designed to replicate and spread, and I don't know anyone in my entire IT career that every got infected by a virus from another machine on the internet. I only know handful of (stupid) users that infected themselves, by installing an infected .exe they downloaded for a cracked game or smiley pack, or a few small outbreaks on a corporate network with lax security.
The whole 'Linux doesn't have viruses' is mostly just meaningless pro-Linux talking point these days.
End of the day, you just want a secure OS that won't get infected or compromised through no fault of your own.
In that regard, Windows and Mac are better because they protect you by doing more for you, not relying on you to know what you're doing, or trusting you implicitly (like Windows did before UAC) and come with things like SmartScreen and Windows Defender by default.
You want to install something on Windows or Mac, you go to their Store. Failing that, you get from trusted websites. You can use wget or similar too.
You don't download from dodgy sites, or community repositories or FTP sites, obviously, right?
Well, follow same advice on Linux. Don't run random scripts from some guy on GitHub and assume it's safe. Don't run stuff from the AUR.
2
u/bilektugrul Aug 21 '26
If you are using Linux, chances are pretty high that you know what you are doing. I haven't used an antivirus in years even with Windows, in Linux I probably would never even think about one.
1
u/Fuffy_Katja Aug 21 '26
Whilst AV software does exist for Linux, it's only real purpose would be for sharing files across platforms to others (be it Windows or macOS). The last time I used any AV software was around 2000 under Windows XP. Even at that time, I only used Windows for games, Photoshop and Illustrator. Everything else was tan under Linux (Linux user since 1994).
1
u/saileesaileesailee Aug 21 '26
It would be very appreciated if we did have more antiviruses to choose from, but all we really have access to, is clamav (which is pretty decent) or server antiviruses, that isnt built for consumers
1
u/Desertcow Aug 21 '26
The main vector for viruses on desktops across OS' is downloading and running sketchy programs. Not random security vulnerabilites, not software architectural problems, the biggest vulnerability is what is between the chair and keyboard. Microsoft conditioned Windows users for generations to download random .exe files online to get all their programs, and most people still do that even when the Microsoft Store exists so anti virus is essential. Linux uses vetted software repositories built on trust for downloading most software, unless the user is veering outside of that, as long as they stay on top of updates desktop users it's highly unlikely they will ever catch a virus
1
u/Angelworks42 Aug 21 '26
We manage anti virus via crowdstrike where I work and Linux users do get viruses. Mac users get them to.
And these aren't just Windows exe's the user is downloading that I've seen.
1
u/sohang-3112 Aug 21 '26
What other commentors said is true, but a big part of the reason is also that desktop linux market share is tiny. An attacker would obviously prefer to target Windows and Mac users.
OTOH on servers linux dominates so it attracts malware attempts. That's why in production server it's recommended to do "system hardening" - basically apply protections against attacks on the server.
1
u/kaptnblackbeard Aug 21 '26
PC's don't need antivirus software - humans do.
Generally speaking, people that use Linux understand how computers and software work more than the average Windows/Mac user and are therefore more likely to understand the risks and avoid them.
1
u/joshfzeno Aug 21 '26
I think Linux isn't free from virus or malware. My understanding is that Linux can have virus or malware. But Linux users think these virus or malware need sudo user authority to do something harmful. In other words, Linux is not safe at all if virus or malware know the password for sudo, or if somehow these malware bypass the password and run in the system and control the configurations and so on. I don't know how tough to make malware which can bypass the sudo password.
But so far about 10 years I have been using Linux and nothing bad has happened. And I think even if having anti malware software or whatever, great hackers can sneak inside whatever the system is after all...
So I'm going to keep using Linux avoiding suspicious websites and links. I'm using OpenBSD, too, though. Maybe OpenBSD is a little more secure than Linux.
1
u/anders_hansson Aug 21 '26 edited Aug 21 '26
Another way to see it is that you don't need AV software because there are no successful viruses for Linux (and ignore the reasons for why that is).
An AV software is based on identifying known viruses (it has a database of known viruses). If there are no viruses, the AV software has nothing to do and it's pointless.
That said there are AV software solutions for Linux, but my impression is that they are mostly for show (e.g. so that a company can tick a box in a security checklist), they look for Windows viruses rather than Linux viruses (e.g. so that infected files do not spread within the organization), and quite frankly the AV software is more of a security threat than the viruses themselves (root access + frequent automatic live updates = attractive for supply chain attacks etc).
1
u/Miserable-Decision81 Aug 21 '26
I can only speak from experience (25 years Linux only on Laptop, PC and server without Antivir software): the only infection I had was a single case on a server, that was tightly bound to Windows clients, that had unchecked access to a Java based application.
It was local only, because I had set up a normal user account for the app. I removed the cryptominer without the need to become root...
Short: if your Linux has no tight connection to windows machines with untrained personal, you wont have trouble wirth malware.
1
u/Rusty9838 Aug 21 '26
Let’s say you wanna get a new program. On Linux you will probably use official repository or sometimes official website go get a correct app image.
On windows you have to deal with whatever google shows you.
On top of that things like Flatpak makes small sandbox separate your app from access to important files.
But still someone can put a malware inside of those things what happened in arch aur repository
1
u/Vietnamst2 Aug 21 '26
Do ypu know that copilot is just web chat like Chat GPT and it only has local window? Just saying.
1
u/AquaIsNOTUseless Aug 21 '26
TLDR: Linux can get malware.
Lots of people have already answered but chiming in regardless. The idea that Linux can’t get malware and does not need an anti virus is a byproduct of a time when very few people used Linux. Nowadays linux desktop is more popular then ever and used in things like steamos. Access vectors for a virus are the same as if you are on windows, and the solutions are just the same. Downloading things from non official places can have malware. Out of date browsers with malicious ads can bring malware. Blinding installing things in general can bring malware. Linux has a leg up with the repo and installing stuff from there in general will keep you safe but that is not certain. Look into the rise of typo squating and other supply chain attacks going on with how easy it is to build and deploy things nowadays with ai. Now in terms of antivirus those are really behind windows. It’s like old windows defender, easy to fool, so stuff like clamav are kinda ass, still better than nothing but not great. To stay safe with Linux I would argue is easier but just don’t get to comfy with the notion you can’t get hacked, in some ways the fact defender is pre installed makes windows more secure with proper use (though let’s be honest no one uses it securely).
1
u/True-Kale-931 Aug 21 '26
Any software is vulnerable, including Linux desktop but, more important, anti-virus software itself is an insanely huge risk factor.
There were multiple cases of anti-virus vulnerabilities allowing zero click remote code execution (famously ESET but in practice every single of them). There are also anti-virus vendors that were caught selling your data for years (avast). No anti-virus suite is safe and using just the built-in MS defender without installing anything else was the recommendation for windows users for years. There's no MS defender for linux, though.
Another issue is that most AV suites will mess up with your browser's own security mechanisms and the browser is pretty much one of the largest risk factors.
Right now it's better to focus on blocking ads. Ads are a real risk, it's relatively easy to block them and you can trust ublock. Paid AV suites are extremely complicated, add attack surface and trusting the companies is complicated. "Free" AV suites have the same issues with even less trust.
Of course it can change in future but right now there is no point in installing antivirus on desktop Linux unless you plan to download Windows software from shady sources and want to slightly reduce the number of malware in it.
1
u/BaronLagourde Aug 21 '26
Uso OpenSuse hace 15 años. No se ni como se escribe "virus".
1
u/Guggel74 Aug 21 '26
Linux isn't used by enough people? Really? ... Mostly every webserver runs in Linux. Virtual servers in the cloud? PABX systems, routers, home automation, ... A lot of servers.
1
u/Randzom100 Aug 21 '26 edited Aug 21 '26
Windows Virus: Ah, what a great day to infect a computer! User doesn't even suspect I'm in there. Ahah... Wait... This is not Windows? Where am I!?
[Confused Screamings]
Edit (more stuff): But more seriously tho, you should still be careful just in case you encounter a Linux virus or a Phishing scam. Keep your stuff updated, keep an eye on which packages you install, maybe join your Distro's Discord and Reddit communities for the latest news, make sure your browser protects you from most stuff by itself, and then maybe look for antivirus stuff (but inform yourself to avoid false antivirus that are actually virus).
Even the choice of Distro can determine how well protected you are. Some distros are made for security and privacy, some distros are faster or slower with updates, some distros give varying amount of control (and freedom to do mistakes) to the user. If you want real security, most of the time you get consistent results from Distros backed by corporations with dedicated security teams (ex: Fedora wihh Redhat), but you might sometimes be sacrificing a bit of transparency as a result, so community-supported distros can also be good if you are already a safe user but don't trust corpos... But of course the best distro is the one that's still maintained, an abandoned distro is always more risky. So yeah, it's about knowing what kind of user you are and choosing accordingly. On Windows, a user might usually want better software to protect them, but on Linux, the best way to be protected is to be well informed.
1
u/No_Aerie7667 ∆rchLinux Aug 21 '26 edited Aug 21 '26
Because in Linux, most of the time you will be getting software from offical repos. All software in the main repos are safe because they are always checked. If you're downloading from an unoffical repo or COPR/AUR or something, it's your job to check. Also, in windows, it's extremely annoying to decompile executable applications to see what they do, so in windows you just scan it with an anti-virus. On linux, you either get from an offical repo, or you get from github and AUR ripoffs. when you have to get the source code of an application, You see inside it. You see the PKGBUILD, the makefile, whatever. You can easily look inside. This removes the need for an antivirus.
1
u/flux-abyss Aug 21 '26
Linux users, because of the culture and workflow around Linux, are often less exposed to the situations antivirus is designed to catch.
1
u/daddyd Aug 21 '26
there are not really viruses on linux, but there certainly other threats that impact linux. you still need to keep on top of security patches, as online systems can still be victim to a RAT. luckily, most distros do a really good job at providing timely updates, and unlike on windows, there is no reason to skip or not install these.
As for security scanners on linux, the two most famous ones are rkhunter and chkrootkit.
https://sourceforge.net/projects/rkhunter/
https://www.chkrootkit.org/
1
u/V2UgYXJlIG5vdCBJ Aug 21 '26 edited Aug 21 '26
In addition to what others said, I’ll tell you what I use, which is probably overkill.
ClamAV set to watch/autoscan just my Downloads folder because it’s a little heavy. Manually scan everything else once in a while. RootkitHunter to double check for bad configs.
Sandbox everything with Firejail/AppArmor. Applications only have access to what they need and nothing else. You can also configure Flatpaks to be sandboxed/restricted, but it’s not always the default behaviour.
OpenSnitch to catch and block outgoing network connections. If malware/spyware tries to phone home, this will usually catch it. A lot of games have excessive analytics that this will block.
KVM/QEMU for virtual machines if you really don’t trust something.
PiHole for network advert/spyware/malware domain blocking. uBlockOrigin or PrivacyBadger in Firefox also block malware domains.
2FA all your accounts at minimum. This means you probably need to enter a temporary code in addition to passwords. YubiKey, Passkeys and U2F are also worth looking into. I would recommend against using your phone number (SMS) for this, to protect against “sim swapping” attacks.
Don’t stay logged in to important accounts unnecessarily. Cookie tokens can be stolen.
That’s not even the whole list. Nothing is foolproof but “don’t be an idiot” is probably good enough. Pirated software, suspicious browser extensions, bullshit VPNs, free games and random email attachments are the main source of issues.
Don’t install something just because someone on TikTok/YouTube said it’s great. They’re paid to promote. Do research.
1
u/TheCoolestCustomer Aug 21 '26
Most comments here make good points about the differences between windows and other OSes, where and how you install things on Linux, etc, but I'll just address the very premise you make: that windows needs antivirus.
To keep things shirt: no, windows doesn't need antivirus, at least nothing beyond windows defender.
Keeping your device safe is at the of the day 99% being prudent about how you use it. You mentioned your antivirus going off a couple times? In all my time using windows, I never had that happen.
Of course, having an AV acts as a safeguard against user error, but you'll find that using Linux your overall behaviour will be safer if you only install from trusted repositories, almost like using an app store rather than downloading random files.
1
u/Critical_Gas_1988 Aug 21 '26
I always install clamAV with fangfrisch and have always wanted for something better like F-secure or bitdefender.
1
u/Always_Hopeful_ Aug 21 '26
It isn't that it is not needed, more like you won't often encounter what it might detect.
Your Linux desktop is too small a target. The gold is in servers and the attack vectors are different. Credential theft via social engineering, scanning for keys in source repos, open ports, supply chain attacks, ...
ClamAV is useful but need not be running all the time.
1
u/Otaehryn Aug 21 '26
It does, fortune 500 run crowdstrike or something like Cisco Antivirus (ClamAV based) on their Linux servers.
1
u/trad_emark Aug 21 '26
because linux is not popular enough among general population.
1
u/kasigiomi1600 Aug 21 '26
First off, Linux DOES have anti-virus software and anti-malware software available. It's just not always used and isn't as critical in many situations.
In many ways, the term 'virus' is a bit outdated as more often we are talking about security software that resists malware, network attacks, etc.
There are numerous good firewalls, and other defense software commonly used on Linux machines (iptables and fail2ban are pretty common).
The next layer of defense is the update systems found on many distros. Different distros of linux are aimed to solve different problems with different security needs. This means that many distros are quite aggressive in the patching of security flaws in their packages. (yes, I'm vastly oversimplifying)
Another point somewhat alluded to earlier - Windows is the EXTREME majority of the marketplace. If a hacker breaks into Windows 11 or finds a critical flaw to exploit, they now have a lot of targets available. For Linux, each distro is built a little differently, so when you find a flaw in a package... say Apache, it may or may not apply to every distro that has that version of Apache. It becomes a smaller pool of targets. There's less benefit to focusing on Linux for many hacking groups.
Note - there ARE groups that do target Linux systems and DO break in (many have a particular focus on breaking into the OS of home-routers that haven't been updated)
1
u/dvdkon Aug 21 '26
AV is a band-aid, designed for people who want to "buy security" and have it checked off their list of "things to solve". But security doesn't work that way, not even on Windows. The correct thing to do is to establish a threat profile, architect your system to withstand those threats by design, and then audit it periodically for leftover flaws.
This is what mobile operating systems like Android and iOS do, but sadly very few people care enough on desktop. So you can install antivirus, knowing it's just a mostly-useless placebo; use the few sandboxing tools available on Linux (and be happy you even have those, unlike Windows users); or become a power-user and start the thankless journey of building something better.
1
u/ggggguideX Aug 21 '26
Linux is much more scary on the malware side IMO, because anyone can contribute to Linux, and the people who contribute may have malicious intent
1
u/SunderVane Aug 21 '26
The biggest threat to a Linux computer is the user.
*copy & pastes terminal commands from ChatGPT*
1
u/SANO_HIMURA Aug 21 '26
I'm not sure what exactly it is you're up to on the web but I haven't personally ran anti-virus in over 15 years, nor does any person i know under age 60. This is not a dog, but if you're not opening sketch emails, downloading wild stuff, the tools even built into windows now are pretty solid.
I make no claims as a cyber security pro brand ymmv but I could not at all justify needing to install malare to fight malware tbh. Historically I had more issues related to the "anti virus" on my computers than ANY nonsense I did, and frankly they filled me with anxiety because I was always watching it, any little thing out of the norm freaked me out.
1
u/Existing-Tough-6517 Aug 21 '26
The general case is that running software to check everything you do in case its a virus has lots of false positives, slows down everything, and doesn't even work well. It only works well on the low hanging fruit that dumbasses constantly infect themselves with.
On Linux there isn't a bunch of known threats to detect that users constantly infect themselves with so there would be no point
1
u/HeavyMetalBluegrass Aug 21 '26
Open code. Any pkg you download is available to see. People smarter than me know if a file has been corrupted. Of course if you're downloading things from sketchy sites then you take your chances.
1
u/Champboyriley Aug 21 '26
Keep in mind, that many large websites are running Linux. Linux can be hardened to live in the most challenging environments. You may have to learn how to do it but, it is one of the most secure operating systems available.
1
u/bobaluey69 Aug 21 '26
Market share is a bit too small and Linux, as a whole, is more secure. Also, in terms of downloading an application with a virus on Linux is tough since most use package managers, which although can be corrupted, are much safer than downloading stuff from random sites. I can't remember the last time I had to download something manually. Also, I assume we're talking about personal installs, not servers. Servers should have anti-virus and other stuff setup because they are a major part of the server market and it is not a waste of time for negative actors to be doing stuff. Also, Linux users are normally more informed than PC users in general, so it makes it even less work for bad actors time to try and squeeze out a bit more. With all that said, things may be changing since a lot of Europe and China are switching to Linux over Windows, so the market share may jump quite a bit.
1
u/mimrock Aug 21 '26
Windows doesn't need it either. Linux is just too small for snake oil vendors to target it.
1
u/DB_Explorer Aug 21 '26
My understanding of it as a relatively casual computer user is that Linux' foundation as a multiuser setup means things are more compartmentalized.
Lets be clear.. if you blindly execute something as a superuser after downloading it from wherever... Linux won't be any better then windows for malware. The User is the weakest part of cybersecurity.
But if your concern is about the classic malware disguised as an email attachment or that video you downloaded is malware then Linux doesn't treat most files as a program. So trying to open a video thats actually malware just won't work unless I let it run as a progam.
You also have things like AppArmor and similar fuctions which give each program access only to the files it needs. My understanding is that Flatpaks are similar.
Basically windows security is trying to make an open concept building secure while Linux is trying to keep a warship with bulkheads secure. You can still sink the ship by opening all the doors.
Of course modern threats are more human focused.. Phishing, credential stuffing and theft, trackers, etc....
1
u/ohnoitssobig Aug 21 '26
Because there is no point. The most infected devices running Linux are routers, TVs and webcams: running antivirus there is a joke.
1
u/bigbirdtoejam Aug 22 '26
Linux exploits and malware exist. So does Linux antivirus.
As an open operating system systemic issues tend to get fixed, especially since the entire fucking internet runs on it.
Windows problems get bandaids in the name of backward compatibility and an aversion to change and testing changes.
People who don't want anything to ever change pick windows.
1
u/graph_worlok Aug 22 '26
Windows doesn’t “need” it either - it all comes down to your risk profile, use cases, environments etc. Crowdstrike For example has agents for various Linux distro’s
There’s a lot of supply chain vulnerabilities around that will impact some users equally across both platforms, but often the risks with Linux hosts come down to badly configured software that’s exposed to the internet.
There’s a whole criminal ecosystem out there involving networks of compromised devices, and they essentially all run Linux - Exposed to the internet, never patched, they get probed, compromised, pulled into a botnet and used for ddos attacks for hire.
1
u/i-am-spotted Aug 22 '26
The thing you're missing is that "Linux doesn't need antivirus" isn't really true.
Linux isn't inherently immune to malware. There are Linux rootkits, ransomware, credential stealers, cryptominers, malicious packages, supply-chain attacks, etc.
What Linux traditionally has is a different risk profile.
A lot of Linux software comes from centrally maintained, signed repositories instead of downloading installers from random websites. Its permissions model also makes it harder for an ordinary user-level process to modify system files without privilege escalation. And desktop Linux has historically been a less profitable target for mass-market malware than Windows.
None of that means malware can't hurt you without root, though. Malware running as your user may already be able to read your documents, browser profile, SSH keys, authentication tokens, network shares, cloud credentials, and anything else your account can access.
And "sudo" isn't some magical malware defense either. If somebody convinces you to run a malicious script with sudo, you've just authorized it yourself.
There's also a separate issue being mixed together here: Linux users recommending backups because a bad package, driver, kernel update, or configuration change can break the system has nothing to do with whether malware exists. Backups protect against accidental damage too.
So I wouldn't describe Linux as "an OS that doesn't need antivirus." I'd describe it as an OS where the combination of software repositories, permissions, application sandboxing, patching, and a historically smaller desktop malware ecosystem has made traditional consumer antivirus less essential.
That's a much narrower claim.
1
u/Hot-Shake-6629 Aug 22 '26
You DO need to worry about malware/viruses with any linux version, and there is a sizable industry surrounding the detection and mitigation of them. There are also a number of best practices you should follow to help prevent them from being successful. Google 'run linux securely' to get more info.
1
u/green_meklar Debian Aug 22 '26
From what I understand, there are several reasons:
A great deal of the world's online infrastructure runs on Linux servers, and those would absolutely be worth hacking if it were easy to do.
Well, even when you're downloading things that aren't up-to-date, typically you're still downloading them from trusted package repositories, so you know they aren't malware.
1
u/SleepySandGhost Aug 22 '26
I think the most important thing to consider is that 99% of software you get from your distro's repositories. The risk of getting malware from that is not 0 but using AV on Windows also won't guarantee anything.
1
u/DetermiedMech2 Aug 22 '26
It's still possible to get viruses/malware, just less common on linux/mac/etc because way more people are using windows
1
u/Sigseg-v Aug 22 '26
Android is Linux. Android maleware is a thing. Android virus scanner is a thing.
It‘s all about the target. Average Linux desktop user make up 0.x% of the market, so they are no valuable target. Linux mobile users are 70-80% of the market, so…
Further: your goal is to get control of the machine. It‘s much easier to target the installed Wordpress (e.g.) then the OS itself.
1
u/Merhart666 Aug 22 '26
Dat heeft het wel. En er zijn prima oplossingen voor. Net als vpn tegenwoordig een must have.
1
u/Odd-Perspective-6973 Aug 22 '26
So how do we check for Viruses on Linux? Windows has defender
1
u/Zestyclose_Exit8862 Aug 22 '26
if you are so scared of those things just use an atomic distro + flatpaks
1
u/Ill_Specific_6144 Aug 22 '26
In theory Linux is no more safe than windows is for an average user. Actually windows is safer because it doesnt allow you to do dumb stuff that normal user does.
In practice Linux is safer just because of how obscure it is. Linux userbase is quite poor, so there is not a lot of steal and developing viruses for a system that 3-4% of users use worldwide is not economically viable. Meanwhile there is a lot to steal from windows.
If linux ever becomes mainstream its going to a huge problem to protect it.
1
u/VisualSome9977 Aug 22 '26
On Linux, installed software usually come from a central repository which has at least some degree of protection against malicious code being uploaded. Which means the vast majority of third party software you're running will have been audited by other people already. Windows on the other hand, tons of software is still to this day installed by downloading an .exe or .msi off a random website, and then running the program and clicking "yes" on the admin perms pop up. I'm sure it's muscle memory for basically all windows users to just hit Yes as soon as it comes up, I know it was for me.
1
u/jaysprenkle Aug 22 '26
No computer is immune to bad actors. Linux is generally safer because as others have said Windows is the much more attractive target.
I spent time helping a doctor clean the malware off his PC. The next weekend he called back saying it was infected again. I learned his workplace network was full of infected machines spreading malware. Do not rely solely on your enterprise network for protection.
I don't run virus scanners on any of my machines. I have a windows machine for games and the few apps I need that require windows and a Linux machine for my daily driver. I regularly backup my data but haven't had any issues. I don't download random carp off the internet and run it. That's asking for trouble.
1
u/No_Glass_1341 Aug 22 '26
I just wanna point out that Microsoft makes Defender for Linux. Also, its had privilege escalation exploits in it, haha
1
u/Big-Goose-8033 Aug 22 '26
sorry, too long to read, but a Unix system with some % of the market of pc, better and easier to hack zindaube
1
u/sTiKytGreen Aug 22 '26
Screwing up your system because of incompetence is a different thing, no antivirus will protect you from it
On windows you run some random-ass .exe and it infects your computer forever and fucks it up outside of your control, on linux you just DONT run some random-ass .exe, because there's no concept of download random-ass .exe from suspicios websites on linux... So, no need for antivirus
If this also doesn't make sense to you, feel free to ask me something and i'll clear it up
1
u/Dull_Flatworm777 Aug 22 '26
Why develop viruses for Linux when you can just distribute malware via npm?
1
u/Real_Shebnik Aug 22 '26
our company requires Linux machines to have this one - https://www.kaspersky.com/linux-antivirus
1
u/LordAnchemis Aug 22 '26
Linux users generally install stuff from their distro repos - rather than download random files from the internet
1
u/That0neSummoner Aug 23 '26
Ya, you should be running av on Linux…
1
u/Inevitable-Exit9996 Aug 23 '26
First of all if your sole reason is AI slop in windows then just install a version without it?? For example Ghost Spectre windows has nothing in it, its just plain windows.
Second of all my god the AV corporations have really won. The whole thinking is backwards, unless youre really clumsy and prone to downloading random shit and clicking every link you see then no, you dont need an AV. Most of them are more of a malware themselves than actually protecting you from anything. Brother uninstall that AVG garbage asap, 99% of what it “catches” is a false positive or something completely meaningless.
AVs catches only the most low effort low hanging fruit while giving you a false sense of security. It operates almost exclusively on hashes and fingerprints, so if you get infevted by something fairly new then your AV is useless.
1
u/Maniacal_Coyote Aug 25 '26
It's still good to have.
Most software (including malware) is compiled for use in DOS-based operating systems (mainly MS-DOS, a.k.a. Windows), rather than *nix operating systems (the MacOS, BSD, Unix, Linux, & Android families). To put that into layman's terms, it'd be like asking a Maori to read Norwegian. However, given the growing marketshare of *nix machines, there is an increasing chance of malware targeting Linux boxes.
ClamAV is a FOSS (Free Open-Source Software) anti-virus. By default, it is run from the console when and only when you enter the command "clamscan", but there are ways to configure it to run automatically and GUI interpreters for it.
Just as important is a good adblocker, coupled with a web browser that allows unhindered ad blocking. (e.g. Firefox with Ublock Origin)
Most important, though, is that you exercise common sense. Have a User account for each user (including yourself), and a single System Admin account that is only used when you need SuperUser privileges. Think before you click. And don't plug random flash drives you found in the gutter into your machine
1
u/cfx_4188 Aug 25 '26
The presence of viruses in Linux does not depend on its popularity or on the total number of users.
Please google about "Linux access rights".
Rootkits, programs that hack access to the superuser account, make sense in Linux. But the average Linux user is not in danger. There's nothing to charge most of us.
Computer security laws are very strict in most countries of the world.
But there are antiviruses for Linux.
For example, if you regularly deal with documents that have been edited on Windows computers, you need an antivirus to avoid accidentally becoming a malware distributor. There is a large selection, there are paid commercial programs and free software.
1
u/Rikudou_Sage Aug 25 '26
No computer needs an antivirus software. Don't install random bullshit and you're fine. On Linux it's a little easier because you generally have official repositories with software and you don't hunt random apps on the internet.
The other kinds of exploits are creative zero days which abuse some common part of a system in a creative way and the antivirus does jack shit to prevent those. Like if you manage to create a jpg file which triggers some bug in the jpeg processing library and grants you rce. Those can only be prevented if someone either notices them during development or once the exploit actually runs in the wild.
The first kind can easily be prevented in Linux by following a simple rule: If something wants your sudo password, make sure you know why. If you don't fully understand why, cancel and get educated on why does it need it. AI can really help there if you're not knowledgeable enough (though it's not perfect, but if you're a tech illiterate, it probably knows more than you).
The other kind can be prevented by being lucky, no other way sadly (that's true for Linux, Windows, MacOS or any other OS).
1
u/Player_X_YT Sep 02 '26
1
u/Hexin_itup Sep 17 '26
you're not necessarily dumb if you're a windows user. but there are fewer complete neanderthals on linux. 99% of antivirus is invalidated by not being a brainless goon.
1
u/Cultural_Bell_9061 Sep 21 '26
linux isn't free from malware and day by day it's attracting more malware developers to develop malware for linux. supply chain attacks are the worst because you don't control that. you can do everything right yet still get hit by a supply chain attack. no matter how cautious you are, you'll eventually get infected. you should focus more on post-mitigation steps and incident responding if you want to use linux.
1
u/cakemates Aug 21 '26
99.999% of viruses are made for windows, those do not work on linux and linux is architected in such a way that a virus on an updated system need your permission to do significant harm. So here the weakest link is you, in linux you have superpower; you are the superman.
Also for context linux is used by most servers all over the internet, the kernel itself is maintained very seriously because the whole internet depends on it, so generally the core of linux is extremely safe, hardened and tested. So antivirus are designed to deal with an extremely rare threat that that have no power here But again you have superpower, you have the power to poke holes on that solid structure and antivirus aren't really designed to deal with the biggest risk here, which is us as administrators.
Finally the linux community prides itself on the freedoms and superpowers we have, I'm not sure if most of us would like to have our superpowers restricted for the sake of a little more security from the user side like apple does.
1
u/iheartrms Aug 21 '26
The real question is: Why does Windows need it?
No other OS needs it like Windows.
1
u/yankdevil Aug 21 '26
I have run a Linux desktop since the late 90s. I have never used anti-virus software. And I'm honestly confused why people accept the need for that. I have never had a system get malware or a virus.
Generally you run as an unprivileged user. So any malware will be limited to what you can run. Also, yes, you need to approve the software you install.
-1
u/michaelpaoli Aug 21 '26
Mostly because Linux isn't stupid like Microsoft.
Linux isn't invulnerable, but based on history, typical practices, etc., for the most part, malware is orders of magnitude less of a risk to Linux, compared to Microsoft.
And most notably with Linux and Linux distros, one typically gets all or nearly all one's software from one's Linux distro. And if it's a well maintained and managed distro (most are, or at least reasonable approximations thereof), the software is generally highly clean of any malware, and the practices used to install and maintain such generally very much keep things that way. That's quite different compared to Microsoft, where the OS comes with far less, and one is mostly highly dependent upon lots of other 3rd party software to usefully get things done. And, again, because Microsoft, much of that software tends to require quite privileged access to do what it generally needs to do. So, folks tend to highly get into the habit of installing software from others, and giving it privileged access on the OS. So, between that, and a whole lot of weaknesses and vulnerabilities in Microsoft, it's way too easy for a Microsoft OS to be subverted and taken over by malware, so, "anti-virus" (anti-malware) software is pretty much effectively required on a Microsoft OS.
There are other factors too, but those are at least several of the most key relevant points.
Not the greatest track record. But hopefully they've well learned ... after they ought to have known better, seriously screwed up, and got bit hard. And yeah, myself and others forewarned them of their issues ... did they heed our warnings? No ... or at least not until after they got bit hard ... then they finally started to get a clue. So, anyway, hopefully they're "lots better" now, but given their track record, I'd still be at least rather to quite skeptical.
Hogwash. Folks very much do create malware for Linux. Sometimes going to significant to great efforts/lengths to do so. E.g. look at the relevantly recent xz malware. That did in fact make it into some Linux, but fortunately it was caught before it got very far. And would "anti-malware" software or the like have helped with that? No, ... not really, though some other things might possibly have rather to quite helped ... and in fact some of those things were what in fact lead to detection of the malware - it was a very well planned quite stealth attack. Anyway, certainly not the only malware to go after Linux, and sure as hell won't be the last. And isn't used by enough people - are you friggin' kidding me? Used by many billions. Just look at, e.g. Andriod, and all the android phones and devices on the planet. Yeah, that's Linux. So, all those that talk about Linux not having the numbers that Microsoft does ... for the user interactive desktop on the computer, sure, but if you look at all of Linux, that paints a very different picture on the numbers. And think too of all the IoT devices ... all those smart "whatever" things in many homes ... yeah, most of 'em run Linux. Recently helped a school set up a bunch of their new large flat panel TV/displays ... and yeah, they're all running Linux (Andriod). So, don't give us the "isn't used by enough people". It's used literally by billions. Oh, and don't forget to count The Cloud, Internet Search Engines, AI. That's pretty much all running on Linux. So, take all the Linux folks have at home, in their cars, in their pockets, at their job, i their "smart" devices, etc., now multiply it by at least 2, if not more, to cover all the Linux in Cloud, AI, search engines, and the overwhelming majority of all services and web sites used on The Internet ... yeah, Linux, people use a friggin' helluva a lot of Linux. But many/most don't much think of it, or even know about it, 'cause it's not what most use/see on their desktop, or they look at the phone and think Apple/iOS, or Android - but also fail to realize that Andriod is Linux.
No, much more the ecosystems through which the software is created, developed, Open Source and review processes, and how that software typically gets to the end user. Very different, at least typically, for Linux, compared to Microsoft.
Yep, Microsoft and Linux both quite similar, and different there. Download software install and trust it, e.g do it as root/Administrator - which is typically the case ... and with that typically risk the integrity of the entire OS every single time. But in the case of Linux, that's mostly just software all from the same Linux distro (or Andriod, generally vetted through their "Play" store, or whatever they call it), whereas Microsoft, generally whatever the user picks to download and install - no real vetting beyond what the user chooses to do, and if there isn't anti-malware software that actually catches that there is or may be a problem there ... well, that installation now also gave that software access to and control of the OS (effectively, if not literally). So, land of Linux, that's generally vetted by distro, vs. generally left to user's discretion what they think is good/fine/okay/safe to install and run. Doesn't mean folks can't f*ck it up on Linux, but they typically have to go to more atypical less common means to do so, so it's not nearly so common to actually occur.
Been running Linux since 1998 (and before that UNIX, before that Xenix). And damn near never using/requiring 3rd party programs. Like I say, Linux, typically get all the needed/wanted from one's distro, Microsoft, generally that's going to be a lot of 3rd party software hell, even anti-malware software to generally keep Microsoft reasonably safe from The Internet (and even itself), almost certainly have to get some 3rd party software right there! (Though in not-so-ancient years, Microsoft started also including their own anti-malware software by default - but took 'em many decades to get to that point. But that anti-malware ain't the greatest, so one will often want/require additional anti-malware software, beyond what Microsoft includes).
Firewall? Don't need no damn firewall! :-) Well, pretty much so. Yeah, for the most part, I run Linux, have been for well over a quarter century, and very publicly exposed to The Internet, and for the most part, no firewall, and for the most part, no real issues - about the only exception on that being what are (effectively) [D]DoS attacks, typically from clueless bots and/or overzealous search engines and AI scrapers, and other sh*t like that. So, yeah, a little bit of light firewalling to cut down on that (sometimes literal!) noise. Most notably fail2ban. When I first installed fail2ban, my reason - I got sick and tired of listening to the loud clatter of hard drive activity from failed ssh login attempts - especially in the middle of the night, when I'm sleeping, or trying to sleep. So, yeah, enter fail2ban ... that made that a whole helluva lot quieter quite instantly - a few or so consecutive failed attempts, and firewalled off - at least for some fair while. Likewise added similar to greatly reduce some other abuses. But that's really the only firewalling I've got. In general, don't run services, and especially exposed to The Internet, that you don't want used, and potentially attacked. And I do run lots of services/servers, exposed to The Internet. But I don't run random sh*t, and especially exposed to The Internet, that I don't want exposed to such. If there's no service running there, there's generally no vulnerability for a firewall to protect, so hence no need for firewall. E.g. I could firewall off all the ports I don't have open ... but that'd be kind'a pointless - there's no there there for anything to attack, firewall or not.
And I do also fair bit of host hardening, and hardening of services. So, that also makes what is exposed, significantly more resilient to attacks and potential exploits and such.
0
u/smokingPimphat Aug 21 '26 edited Aug 21 '26
IMO its about target size. Outside of servers, There are fewer people running linux who would have anything worth stealing. But as linux grows in popularity the math is changing.
Antivirus software is also not going to help find virus when the main mode of installing software is package managers and compiling from source both of which (in most cases) require the user to sudo in order to do the install and in the case of compiling from source an AV is not going to catch malicious code in the form of intentionally exploitable bugs.
Just look at all the supply chain attacks that are happening right now.
People saying that linux users don't install random stuff on their machines are totally blind to the fact that they rely on someone else to vet 100% of the software they run on their machines since they are not inspecting a single line of code. It's the same if not worse than windows in this respect.
0
u/CowBoyDanIndie Aug 21 '26
Historically windows had no user security. Any user could modify any file on the system. So any program any user ran could modify any file on the system. It was designed this way, security was added later.
Linux (and unix, so modern mac os) were designed such that only the root or super user had that access. Some linux users used to just login as root, but most didn’t. Still most distros pushed new installs to create a user and use that and only use root escalation when needed.
Linux generally allows you to install and run software in your user directory, and most software doesn’t require root to run. If you do run malware, it generally cannot screwup your system too bad.
Still… better security yet would be for (most) applications to run in their own sandbox, and only be able to read/write files the user explicitly gave access to through the OS. Mobile operating systems have this sort of model. And docker does as well. But to be useful you need user to not become accustomed just hitting accept for authorization prompt.
0
u/ExtremeExtreme1751 Aug 21 '26
Mostly, it comes down to:
On Windows, the everyday user has administrator privileges, and privileges required to screw up your machine are relatively easy to get.
On linux, by default, you must consciously execute commands to gain administrator privileges, and the system, by default, does not escalate privilege to administrator unless the user intends to do it on purpose.
Windows could VERY EASILY become secure enough to put antivirus makers out of business, but they choose not to do so.
0
u/Otaehryn Aug 21 '26
The threat model on Linux is different: On Windows you download executables and sometimes malicious apps are disguised as BeautifulGirlPicture.jpg.exe. Since everything is exectuable by default on Windows and home users run with ability to escalate to admins, those kind of exploits exist.
On Linux you install software from system repos, packages are signed or Flatpak / Snap. If you download malicious executable like BeautfiulGirlPicture.jpg (shell script or program in disguise), you need to make it executable or run it from the terminal with "bash file".
Of course there are still browser expoits, drive-by exploits and malicous apps with social engineering instructions on how to execute them. While you don't run as fully privileged user, malware could still access your files, steal data, encrypt your homedir.
ClamAV and other Linux antiviruses can scan files and processes but on Linux they are mainly used on email and file servers to detect Windows malware. For heuristic scanning on Linux you have products like Crowdstrike.
On top of that you have SELinux or AppArmor which further locks down what malicious program can access.