Apple bought this on themselves through pure greed and a sense of entitlement.
Before I start to criticise Apple, I am here on these forums as hugely admire Apple's hardware and OS level software.
I'll always celebrate Apple when it brings out amazing products such as the new Macs, the new iPhones etc. etc.
But I think it's fair to criticise them when they deserve it.
I feel that its Services is a massive source of rot, which is damaging Apple as company.
So the EU are right to act as they are in this case (when they will almost certainly name Apple as a gatekeeper).
Services is obviously a high margin business that is growing as iPhone revenue is starting to slow, which is why Tim Cook is letting it happen.
Of course, it's business school basics that if you can get extra revenue from your existing customers and still keep them, you should.
And in fact the duty of the CEO - who in reality, works for the shareholders - to maximise revenue.
But the CEO can also make the argument to the shareholders, that gaining every extra $ can sometimes be the long term detriment of the company.
Tim Cook seems to be unwilling to make this argument, which I simply don't like, as I believe that he is profoundly wrong not to.
***
The App Store at the start, was fantastic and allowed devs to reach a huge audience and not have to set up billing and distribution systems. Consumers got a (mostly!) safe curated store.
Nowadays the App Store seems more about Apple jealously guarding its revenue from it and using it as a platform to claw additional incremental revenue - App Store ads, even more App Store ads and clamping down on anyone trying to sell anything without giving Apple their cut - NFTs and so on.
I haven't got an MBA, but I'm aware that as products and markets reach maturity, different rules & norms come into play and that fair competition has to be ensured and companies generally don't enjoy as high margins as before.
It also encourages companies to create new products and not just sit on their 'gold mine', which is all for the good.
This is exactly what the EU is aiming to ensure.
Apple is behaving although this simply doesn't apply to them and that they don't have to budge an inch.
***
And as for security: as many have pointed out, the Mac uses notarisation.
And there has still been security issues on the App Store.
Just the other month, there was an issue with apps being able to store Facebook login credentials. Why didn't Apple catch that? There's numerous other examples too, just search for them.
The reason is, is because the App Store isn't really about curation and user safety as a priority anymore. It's about - yes you've guessed it - revenue. For Apple.
As for sideloading other App Stores. Well, you won't have to. And if a store gets a bad reputation, just like real life stores no-one will use them.
Having said that, I will concede a point in Apple's defence though & agree with some other posters here - there will be a lot of scams from 3rd party app stores.
But I can't help thinking that we wouldn't have got to this point if Apple had compromised.
But it refused to, as revenue was more important to it than the longer term health of the product. And now there's going to consequences for us all, including Apple (at least in the EU!).
***
P.S. I'm in the UK so this may or not apply to me (depending on which government is in place and if Apple decide to only apply these rules in the EU only), nor am I a dev etc. so I have no skin in the game, so to speak.