It’s not the case that viruses can’t exist on Linux, it’s just very improbable through normal usage. The key difference is that the overwhelming majority of software installed on Linux is through a package manager, which is a tool that downloads software from a maintained, trusted, and vetted repository of software. So instead of googling “Firefox download”, clicking on (hopefully) the right link (and getting this right gets harder and harder with Google fucking up search results), and downloading the software from the website, you simply execute a command in your terminal like apt install firefox (for Debian-based systems, command can vary by distro you’re using) and it pulls the software from a trusted repository. This alone eliminates the most common attack vectors, since usually Windows users get viruses by downloading random executables off the internet.
Generally, the way you get viruses on a Linux system are through finding/exploiting vulnerabilities in software which is very hard to pull off generally and are usually resolved fairly quickly once they’re discovered (And of course, Linux is not unique in this respect, any computer can be target of such attacks).
It’s not the case that viruses can’t exist on Linux, it’s just very improbable through normal usage. The key difference is that the overwhelming majority of software installed on Linux is through a package manager, which is a tool that downloads software from a maintained, trusted, and vetted repository of software. So instead of googling “Firefox download”, clicking on (hopefully) the right link (and getting this right gets harder and harder with Google fucking up search results), and downloading the software from the website, you simply execute a command in your terminal like
apt install firefox
(for Debian-based systems, command can vary by distro you’re using) and it pulls the software from a trusted repository. This alone eliminates the most common attack vectors, since usually Windows users get viruses by downloading random executables off the internet.Generally, the way you get viruses on a Linux system are through finding/exploiting vulnerabilities in software which is very hard to pull off generally and are usually resolved fairly quickly once they’re discovered (And of course, Linux is not unique in this respect, any computer can be target of such attacks).