Microsoft's Safe Systems Programming Languages Effort (Rust)

by Leaceon 5/22/2020, 8:03 PMwith 17 comments

by server_boton 5/22/2020, 9:57 PM

Good intro to the benefits of Rust for a broad audience, but one important omission: the Use-After-Free and Double-Free protection he mentioned is provided by compile-time static analysis, but Rust also does runtime bounds checks to prevent classic stack smashing (with minimal performance overhead).

That may not seem like a big deal for the x86_64 world where modern mitigations largely make shellcode a thing of the past (hence heap exploitation, ROP/JOP, etc) but it is a BIG DEAL for embedded microcontrollers that lack OS/HW memory protection - an area where #![no_std] Rust shines.

As a security researcher and not a developer, let me be very frank: you should STRONGLY consider Rust in place of C or C++. But know that release profile builds don't do integer overflow checking, so don't get cocky :P

by mellingon 5/22/2020, 8:36 PM

He mentions this book as “the book” on Rust.

https://www.amazon.com/Rust-Programming-Language-Steve-Klabn...

I think it’s also available for free online. Here? https://doc.rust-lang.org/book/

by jbrittonon 5/23/2020, 3:28 AM

One thing I like about C as a systems programming language is that it is easy for every other language to bind to it. I’m fine with C++ if the external interface is extern “C”, but that is often not the case. I don’t know how easy it is for other languages to bind to Rust. It would be nice if a language could automatically generate Swig definition files or something similar. However one is going to run into language semantics and impedance mismatches with richer languages. The simplicity of “C” makes a nice bind target. Although I have yet to see a thorough binding to Win32, so I suspect the preprocessor makes this difficult.

by akmittalon 5/22/2020, 9:55 PM

Defination of systems programming language is really contradicting. Go was sold as systems programming language in beginning.