Stories
Slash Boxes
Comments

SoylentNews is people

posted by martyb on Tuesday June 22 2021, @09:47PM   Printer-friendly
from the anti-accident? dept.

The ISRG wants to make the Linux kernel memory-safe with Rust

The Internet Security Research Group (ISRG)—parent organization of the better-known Let's Encrypt project—has provided prominent developer Miguel Ojeda with a one-year contract to work on Rust in Linux and other security efforts on a full-time basis.

As we covered in March, Rust is a low-level programming language offering most of the flexibility and performance of C—the language used for kernels in Unix and Unix-like operating systems since the 1970s—in a safer way.

Efforts to make Rust a viable language for Linux kernel development began at the 2020 Linux Plumbers conference, with acceptance for the idea coming from Linus Torvalds himself. Torvalds specifically requested Rust compiler availability in the default kernel build environment to support such efforts—not to replace the entire source code of the Linux kernel with Rust-developed equivalents, but to make it possible for new development to work properly.

Using Rust for new code in the kernel—which might mean new hardware drivers or even replacement of GNU Coreutils—potentially decreases the number of bugs lurking in the kernel. Rust simply won't allow a developer to leak memory or create the potential for buffer overflows—significant sources of performance and security issues in complex C-language code.

Previously: Linus Torvalds: Don't Hide Rust in Linux Kernel; Death to AVX-512

Related: Microkernel, Rust-Programmed Redox OS's Devs Slam Linux, Unix, GPL
Following Layoffs, Mozilla and Core Rust Developers Are Forming a Rust Foundation


Original Submission

 
This discussion has been archived. No new comments can be posted.
Display Options Threshold/Breakthrough Mark All as Read Mark All as Unread
The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
  • (Score: 2) by DeVilla on Saturday June 26 2021, @09:52PM

    by DeVilla (5354) on Saturday June 26 2021, @09:52PM (#1149758)

    Rust isn't a bad language. Being able to stay compatible with the C ABI while providing higher level features and better memory safety ain't bad. It's performance isn't broken in any way that it can't improve in time has C has been able to over the years.

    The big thing that make it inappropriate for the kernel and any important infrastructure code right now is that it can't target enough architectures. Once the compiler front end for GCC is stable and assuming it remains well maintained, that stops being a problem. There are other possible fixes such as adding more targets to llvm or getting the entire world to agree to deprecate any platform llvm doesn't support, But there are roads forward here.

    There is also the risk that rust will start retro-fitting more features in as other languages have been unable to resist doing. C seems to avoid doing that by defining itself as a language that would add any high level features. Things only seem to creep in after all the compilers have manage to add it. Usually back porting extensions from C++, but sometimes not as with member initialization. Rust seems to like to stay in "active development". It will be hard for them to resist.

    Starting Score:    1  point
    Karma-Bonus Modifier   +1  

    Total Score:   2