3 ms·
Just want to point out that not that long ago redox-os (the microkernel OS in Rust) asked people to test it. People were able to kernel panic it, get privilege
by greenhouse_gas 9y ago
Just want to point out that not that long ago redox-os (the microkernel OS in Rust) asked people to test it.
People were able to kernel panic it, get privilege escalations, and DDoS it. In short, it had the same same issues a C based kernel would get.
It's true that it's still heavily in development and doesn't offer any guarantees whatsoever, but I think that it should be pointed out that just because your language is good, doesn't mean that your end result will be good (and vice-versa, C based kernels like l4 and C based projects like SQLite have been formally verified (at least SQLite was verified after compilation, so they check for undefined language constructs.))
- peoplewindow 9y agoCan you link to that? I'd be curious to see how they did those things. I guess Redox has a lot of unsafe Rust code?
- dtolnay 9y agoHere is the "Redox Crash Challenge": https://github.com/redox-os/redox/issues/1136 https://github.com/redox-os/redox/issues/1136 According to the Redox book, at last count they had 70 cases of unsafe across 4500 total lines of kernel code. https://doc.redox-os.org/book/introduction/unsafes.html https://doc.redox-os.org/book/introduction/unsafes.html
- steveklabnik 9y agoSafe rust doesn’t mean “no bugs”, these kinds of issues aren’t inherently memory safety issues, they can also be the product of logic bugs.
- mercurial 9y agoWell, I mean, one of the issues listed is "getting a lockup with ls * on the default directory". Sure, Rust (or any other language, even something like Idris) is not a magic pill, but at that stage of development, you can't expect much. I would still say that it is, on average, a lot easier to shoot yourself in the foot in C than in Rust.