SELinux is made to prevent this kind of issues. Or rather: To encode the safety advice made by the author as a set of rules/constraints and ship it to everyone.
Now the question is: Is SELinux the sawstop the author asks for?
SELinux is bearable on a server, but I don't know if I could live with it on a dev workstation though (to be fair, as a mainly Windows dev, I never made the effort to "learn" SELinux properly).