MMUs and security
@doperative, the MMU of course has enforced memory protection between processes at least since IBM started using them in the 1960s. ASLR prevents situations where someone subverts existing code *within* the application.. usually either overwriting a portion of the program, or jumping to a piece of code in the program, where it does something different when called "naughtily" than it was intended to do. Since the locations are randomized these become much more difficult.
@Charles 9, no. Popularity doesn't help, but Linux doesn't have so few viruses just because of that. Frankly, Unix *used* to have pretty poor security. But, the Unix community had their "Nimda"/"Code Red" moments back in the late 1980s with Morris worm and the like! So they've been improving security for over 20 years, instead of the few years Microsoft has been taking it seriously. People do look through source code for security problems; Linux distros have much more frequent updates than Windows (no waiting til "patch Thursday", a.k.a. giving exploits 30 days free reign.) They don't include massive mounds of "legacy code" (stuff dating all the way back to Windows 3.1 or even older) the way Windows does. The security systems in Linux are *actually used*, whereas Windows has plenty of access controls that are not even used, resulting in plenty of apparent security that is actually implemented by the shell rather than kernel level. An important one, Linux (as with any UNIX) has an executable bit, so you can't just download some crap into a file and expect it to execute. Windows doesn't. Finally, a nice one, if Windows (or probably OSX for that matter) got a virus, how do you know if your system files are clean? You really don't. Linux distros have a proper package manager, so comparing the checksums between what is there and what is in the packages is easy, and in fact it's entirely possible (in fact easy) to just reinstall all packages instead of "wipe, reformat, reinstall".