JavaScript would have prevented this.
What’s the point of rewriting parts of the kernel in unsafe rust?
it’s not like the whole driver is written in unsafe rust
unsafe is usually used only when you need to interact with something else like low level or ffi
Because Rust is the popular thing in FOSS/Linux at the moment.
For memory safety, which is not unsafe rust
You say that. But the CVE is a memory corruption bug.
Which is worse?
- Entire driver written in a non memory safe language?
- The interface to the rest of the kernel is marked as unsafe and then the other X percent is safe from memory corruption?
Surely if X > 0 then this is still a net improvement?
I don’t know, but I found this article interesting with respect to unsafe Rust - https://lightpanda.io/blog/posts/why-we-built-lightpanda-in-zig
They’re not calling Rust unsafe. There is a memory safe mode and a memory unsafe mode in Rust, and this was built in unsafe Rust which allowed for the memory bug to be exploited
You don’t understand what unsafe means





