For instance, they created the SMB file protocol not from computer science first principles, but as a hack. And so everyone who wants to interoperate with it (e.g. Samba) is then locked in a decade long attempt to reproduce every single bug in their own code.
Incorrect. SMB was created by IBM to share printers and files in the PC-DOS (and likely token ring) days.
Microsoft adapted it for their Windows networking product in Windows NT as an alternative to the IPX/SPX protocol that Novell had.
Andrew Tridge then realized his SMB client/server project would work not just for IBM, but for Microsoft networks as well with a few slight adaptations to evolve the protocol (especially since it wasn't running on TCP/IP in the early days).
Microsoft later adapted it for Windows Vista in SMB 2 and Windows 7 as SMB 3. But SMB 1 still remains a deprecated option because many Linux based NAS devices, in an attempt to skirt the GPLv3, still use an ancient version of Samba that only supports SMB1. (Samba went to GPLv3 about 3 weeks before it released support for SMB2). This is why many routers and cheap NAS boxes still require you to install SMB1 support.
(NAS providers like QNAP, Synology and vendors like Apple chose not to use the GPlv3 Samba after this, and wrote their own SMB2+ implementation). The need for SMB1 should decrease further because the Linux kernel itself has SMB2+ support inside it.
At which point we can truly ditch the nightmare that is SMB1, which is kept around less for Windows and more for devices running Linux. (You need SMB1 for Windows XP and lower and those haven't been supported in over a decade)
The other thing is SMB was for file and print sharing, and Microsoft did the EEE thing with it once IBM was no longer interested in it which Samba had to follow faithfully to be completely compatible.