Microsoft open source windows-drivers-rs, using Rust to develop Windows drivers

Mark Russinovich, chief technology officer of Microsoft Azure and a well-known Windows software developer, announced on social platforms the launch of a new open source project called windows-drivers-rs.

This project helps developers develop Windows drivers using Rust and is designed to support WDM (Windows Driver Model) and WDF (Windows Driver Framework) driver development models.

The current version of the resource library mainly consists of Rust crates, including:

  • wdk-build : Library for configuring Cargo build scripts for binding generation and downstream linking of the WDK. Although this crate was written to flexibly adapt to different WDK versions and different WDF versions, it has only been tested against NI eWDK, KMDF 1.33, UMDF 2.33, and WDM drivers. Older versions of the DDK may be missing linker options.
  • wdk-sys : Direct FFI binding to the API available in the WDK. This includes automatic generation of ffi bindings bindgenfrom them , as well as manual reimplementation of macros that bindgen cannot generate.
  • wdk : safe idiomatic bindings to APIs available in the WDK
  • wdk-panic : The default panic handler implementation for programs built with the WDK
  • wdk-alloc : Allocation support for binaries compiled with WDK
  • wdk-macros : A collection of macros that help make it easier to interact with wdk-sys' direct bindings. The crate is wdk-sysre-exported, and normally crates do not require direct dependencieswdk-macros

Specific examples can be viewed at Windows-rust-driver-samples .

It is worth noting that the project is still in its early stages and is not recommended for commercial use; however, Microsoft encourages community experimentation, suggestions, and discussions on the project. During the development of windows-drivers-rs, the company will use GitHub discussion forums as its primary form of interaction with the community. Currently, the windows-drivers-rs project has received support from Microsoft developer Melvin Wang.

Related Reading:

Guess you like

Origin www.oschina.net/news/259564/develop-windows-drivers-in-rust