
Cloud Vulnerability DB
A community-led vulnerabilities database
A moderate severity vulnerability (GHSA-3qx8-rv27-j6gp) was identified in the kvm-ioctls Rust package, specifically in the VmFd::create_device function. The issue, discovered and disclosed in December 2024, affects versions prior to 0.19.1 and impacts systems using rustc 1.82.0 and newer. The vulnerability stems from undefined behavior and potential miscompilations due to violations of Rust's pointer safety rules (GitHub Advisory, RustSec Advisory).
The vulnerability occurs in the VmFd::create_device function where it incorrectly downcasts a mutable reference to its struct kvm_create_device argument to an immutable pointer, which is then passed to a mutating system call. On Rust compiler versions 1.82.0 and newer, this leads to the elision of subsequent reads of the structure's fields, causing the code to not see the value written by the kernel into the fd member. Instead, it observes the initial value (usually 0) that was set before calling VmFd::create_device (RustSec Advisory).
The vulnerability affects the functionality of the kvm-ioctls package when used with Rust compiler versions 1.82.0 and newer, potentially causing incorrect values to be passed to File::from_raw_fd calls. This can lead to unexpected behavior in virtualization implementations using the affected versions of the package (GitHub PR).
The issue has been fixed in version 0.19.1 of the kvm-ioctls package by correctly using a mutable pointer (ioctl_with_mut_ref) instead of an immutable reference (ioctl_with_ref) in the create_device method. Users are advised to upgrade to version 0.19.1 or later to resolve this vulnerability (GitHub PR).
Source: This report was generated using AI
Free Vulnerability Assessment
Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.
Get a personalized demo
"Best User Experience I have ever seen, provides full visibility to cloud workloads."
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
"We know that if Wiz identifies something as critical, it actually is."