Hacker News new | past | comments | ask | show | jobs | submit login

This absolutist statement is basically meaningless.

Taking Rust as an example (use Swift or even Java if that works better for your use-case), we know how to write Rust code that is guaranteed to be free from common classes of bugs that these zero-click attacks exploit.

Yes, we aren't going to get rid of all bugs, yes, zero-click attacks might still be possible once in a while, but we can make it much, much harder and more expensive, and therefore greatly reduce the set of people who have access to such attacks, and reduce their frequency.




we know how to write Rust code that is guaranteed to be free from common classes of bugs that these

No we don't.

You are trying to shift the sands, by saying "But.. this one thing we can do...", except even that isn't true.

If we did, it wouldn't keep happening, year after year, decade after decade.

But even with peer reviews, with people supposedly knowing how, well.. it just keeps happening.

Do you think every occurrence is random chance? Or is it, maybe, just maybe, that humans can't write bug free code?


In practice safe Rust code never causes use-after-free bugs, for example, and UAF bugs are large fraction of exploitable RCE bugs.

Safe Rust code could trigger a compiler bug that leads to use-after-free, or trigger a bug unsafe Rust code (i.e., code explicitly marked "unsafe") that leads to use-after-free; the latter are rare, and the former are even rarer. In practice I've been writing Rust code full time for six years and encountered the latter exactly once, and the former never. In either case the bug would not be in the safe code I wrote.

I'm certainly not claiming that humans can write bug-free code. The claim is that with the right languages you can, in practice, eliminate certain important classes of bugs.


Can you now?

So there will be no human error? And rust will have zero compile time bugs, ever?

I'm not against improvement, but the absurd assumption that anything is safe. Because nothing is.


I guess kind of nihilist conservatism (“why bother changing anything since there's nothing we can do”) may explain why we are in such a bad situation today…




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: