I am not convinced by the legal argument "windows cannot make its systems secure or else the anti-malware industry would sue them". Linux vendors have survived.
That is not the argument though. Allow me to try and explain this in layman's terms.
When it comes to how operating systems allow a program to operate every operating system this side of UNIX has two modes of doing so. They are called user mode and kernel mode.
User mode is where your typical programs operate. This includes things like video games, browsers, etc. User mode can be seen as a sort of sandbox. The analogy is not perfect but it works. In user mode your program basically gets a chunk of memory and interacts with the OS for everything outside of that. So for example if it wants to draw to the screen it calls the OS which than calls the graphics card driver. If it wants to read from the hard drive it has to call the OS which calls the hard drive driver. Etc. Etc. And for most programs this is good enough. They do not need the benefits of direct hard drive access and benefit greatly from the security that comes from having the OS as a middleman who checks the calls for anything stupid or malicious.
And as far as security goes, this works remarkably well. The built in API of modern operating systems be they Windows, Unix or what ever apple is calling theirs these days is remarkably good. And the days of viruses operating in user mode and breaching the built in security of Windows to mess your system up is basically over and has been since something like XP Service Pack 3. Unless you are running an ancient operating system or are one of those people that absolutely refuse to update for years you are pretty much safe with just the base windows alone.
The issue though is that while this setup is good for most programs it does not work for all of them. Some programs like drivers simply must be able to bypass the system and have direct access to hardware in order to operate. This includes things like drivers. You can after all not have a hard drive driver that stores data to the hard drive by calling the operating system to tell the hard drive driver to store data. And that is where the vulnerabilities in modern systems come from.
So what happens if the driver, the piece of software that absolutely has to operate in kernel mode is horribly insecure? Well, you would think that does not happen but actually it happens a lot. Hardware vendors are notorious for being good at making hardware and than cheeping out on the drivers. Just look at your average printer software as an example and multiply that by 11 for all the drivers your average user can't interact with and complain about to customer support.
And that is how viruses get into your system. A good virus these days is an user mode program that uses innocuous and nominally safe operating system API commands that should with a correctly written driver do absolutely no harm to send commands to a very bad driver it knows is on your system and exploit bugs in that driver to make it do horrible things like for example running your virus code instead of its own. And once that happens you are what we in the industry call capital S Screwed. And not the nice little wood screws that go under your finger nails either...
And there in lies the problem. Once bad code is in kernel mode it can do anything it likes including and not limited to disabling or destroying any other program running on the system. This includes any and all antivirus software that might be running. At the same time, that software can literally do nothing to prevent or stop that unless it also is running in kernel mode. Which is why antivirus software does.
And OS vendors are not unaware of this problem. They each have their own ways of handling it but it all boils down to basically making it so that you can only install drivers that have been tested and certified by the vendor through some certification program that the creators have to pay for. And this too usually works remarkably well.
In this case however, the problem was that one company published a patch for its kernel mode program that was defective. And patches generally do not have to be decertified each and every time because that would make regular updates basically impossible.
So it is not a legal thing. It's just some really bad testing on the publishers part coupled with frankly really bad luck.
Or is that really the case?
Why do all these devices even need antivirus software to begin with? Antivirus software is only really required if you have a machine that is actually likely to be injected by malicious code which in these days basically means only one thing which is the internet. That is why basic corporate security practices which at this point I am pretty sure are even in ISO standards is that devices in large internal networks such as banks, hospitals or airports should be behind layers of security and operating within a corporate controlled network.
Therefore they should not require individual AV protection any more than someone living in a house made of bricks with no windows whose only contact with the outside world is a telephone should require a bullet proof vest.
Indeed, why do they even have access to the internet to begin with? Does your average doctor, administrator or air traffic controller really have to check facebook from his work machine? I think not. And the applications that do interact with outside customers should be hosted on secured servers which should be sufficiently isolated that even if brought down the only thing to fail would be the customer facing side.
So what really happened here is not just some poor developer pushing a bug to millions of people and crashing the world. No matter how much everyone screeches that it is.
Rather it's an open and poignant demonstration of the fact that bad security and computer infrastructure practices are so insanely prevalent in the modern landscape that there is an entire unseen industry of corporate software security built around patching the problems caused by it just barely well enough that everything keeps working. That is until it doesn't.
And when that one point of failure makes a mistake the whole house of cards comes crashing down.
EDIT: Included TLDR.