5 ms·
Memory safety is a very small fraction of the problems a computer program can have, and replacing them by an immediate shutdown is hardly a very useful improvem
by mgaunard 3y ago
Memory safety is a very small fraction of the problems a computer program can have, and replacing them by an immediate shutdown is hardly a very useful improvement on program quality.
- sophacles 3y ago> Memory safety is a very small fraction of the problems a computer program can have And a large fraction of the problems that lead to security situations. Worse, they are often so subtle that they stay in a codebase for decades. > and replacing them by an immediate shutdown is hardly a very useful improvement on program quality. That's a pretty absolutist statement about something that's very context dependent.
- UncleMeat 3y ago"Software quality", in my mind, includes "nobody can send me a crafted text message that gives them remote root access on my phone." Yes, there are security issues beyond memory safety bugs. But these are the issues that are most regularly turned into the most serious exploits and they are hellishly common. All systems security is about layered defenses. "Oh, log4j exists" is not a compelling reason to avoid changes that can mitigate very large portions of security risk. There are places where you'll truly never encounter untrusted input and a crash is just as bad as blasting off and performing whatever unexpected computation, but that's nowhere near the entire existing C++ landscape.
- mgaunard 3y agoDesign by contract improves software quality instead of lowering it. And it explicitly introduces undefined behaviour aka "memory safety bugs".
- keybored 3y agoDesign by contract? That technique which “shuts down your program”/panics on assertion failure? You seem to contradict yourself.