29.3 C
Hong Kong
Friday, October 4, 2024

Your AD here

Microsoft Integrates Rust into Windows Kernel for Enhanced Security and Code Readability

Microsoft Adopts Rust in Windows Kernel, Bolstering Security and Simplifying Code

Microsoft Vice President David Weston announced at the BlueHat IL 2023 conference that the company is in the early stages of integrating the Rust programming language into parts of the Windows kernel. This decision aims to improve security, reduce vulnerabilities, and simplify the code in one of the world’s most complex engineering products.

Rust A Modern Programming Language with Security Benefits

Rust is a modern C-like programming language highly regarded by developers for its focus on memory safety and security. It forces the creation of safe, native code without the overhead of managed languages. The language is easier to write and understand than the current C++ code used in the Windows kernel, making it an attractive choice for Microsoft’s efforts to enhance the kernel’s security and readability.

Microsoft’s Progress with Rust Integration

Microsoft has already rewritten 36,000 lines of code in the Windows kernel and 152,000 lines for a proof of concept DirectWrite Core library in Rust. According to Weston, the performance is excellent, with no regressions compared to the old C++ code. He also highlighted that there is now a syscall, or system call, written in Rust in the Windows kernel. System calls enable user mode applications to interact with internal kernel functions.

Windows 11 Soon to Boot with Rust in Kernel

Weston revealed that Windows 11 will be booting with Rust in the kernel in the coming weeks or months, further emphasizing Microsoft’s commitment to incorporating Rust into its systems. However, the company does not intend to replace the entire C/C++ kernel code with Rust. Instead, Microsoft plans to replace targeted portions of the codebase to remove legacy attack surfaces and modernize the kernel, much like the approach taken with the recently released Linux 6.1 kernel, which is the first to include Rust code.

Anticipated Benefits and Future Outlook

The integration of Rust into the Windows kernel signifies Microsoft’s dedication to enhancing the security and stability of its operating system. With Rust’s focus on memory safety and security, this move will likely result in a more robust and reliable Windows experience for users. As Microsoft continues to modernize its kernel and adopt Rust, the tech industry will closely watch the impact on system performance and security, potentially influencing future programming choices for other large-scale software projects.

Related Articles

Latest Articles