I worked on one project that was essentially one main app and then a plugin architecture where other companies could write modules that would be run inside the main app. My explicit instructions were to make it very difficult to actually write one of these modules (so that our competitors could not actually be competitive) and boy did I deliver! If my company had really wanted to deliver something like this that actually worked (in the sense of other companies being able to make real contributions) it would have been trivial to make everything HTML-based web apps.
I had to endure a roasting session where some junior developers laid into “grampa” for his absurdly bad design decisions. I suppose I deserved it, though, for my poor ethical choices.
Like, I actually had emails from the bosses talking about this shit. I really should have saved them for blackmail - no worse ethically than what I did do.