Use-After-Free Vulnerability in Linux Kernel's virtio-blk Package

linux Updated 02 Oct 2025

Summary

18/06/2025
N/A
Yes i
Unrated
Not published

CVE-2022-50064: In the Linux kernel, the following vulnerability has been resolved: virtio-blk: Avoid use-after-free on suspend/resume hctx->user_data is set to vq in virtblk_init_hctx(). Affects linux versions < 6.0.2-1. Fixed in 6.0.2-1. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored Devnack Mobile apps built by Devnack Design, build and launch iOS and Android apps with a senior product team. From idea to store release Start a project

Background

The Linux kernel is a core component of many operating systems, providing essential services and hardware abstraction. The virtio-blk package is responsible for managing block device virtualization, allowing efficient data transfer between virtual machines and physical storage. This package is critical for performance in virtualized environments, but it is susceptible to vulnerabilities that can compromise system stability and security.

Vulnerability Detail

The vulnerability, identified as CVE-2022-50064, arises from a use-after-free condition in the virtio-blk implementation. Specifically, the user_data pointer in the hctx structure is set to a virtual queue (vq) during initialization. However, this vq is freed during the suspend process and reallocated upon resume, leading to an invalid pointer access after resume. This can result in kernel crashes, as evidenced by the call trace provided in the vulnerability details, which indicates various functions that may be affected by this issue.

How To Fix

Minimum fixed version

6.0.2-1

This is the first release that contains the fix.

sudo apt-get install --only-upgrade linux

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Workaround

Currently, there are no specific workarounds mentioned for this vulnerability. The best course of action is to apply the patch by updating the package as described in the 'how_to_fix' section.

Conclusion

CVE-2022-50064 is a significant vulnerability in the Linux kernel's virtio-blk package that can lead to system crashes due to improper handling of memory during suspend and resume operations. It is crucial to update to the patched version to mitigate any risks associated with this vulnerability.

See every vulnerability recorded for linux →

Share this vulnerability

FAQ

CVE-2022-50064 is a vulnerability in the Linux kernel's virtio-blk package that can lead to kernel crashes due to a use-after-free condition.

If exploited, this vulnerability can cause system instability, leading to crashes and potential data loss during operations involving block device virtualization.

If you are using a version of the Linux kernel prior to 6.0.2-1, your system may be vulnerable. You can check your kernel version using the command 'uname -r'.

You can use tools like Vulert, which monitors open-source vulnerabilities in your software by analyzing manifest files such as package-lock.json. It provides real-time alerts for any vulnerabilities detected.

Detailed information about CVE-2022-50064 can be found in the official CVE database or through security advisories related to the Linux kernel.

Related vulnerabilities

Recent vulnerabilities recorded for linux.

How To Fix

Minimum fixed version

6.0.2-1

This is the first release that contains the fix.

sudo apt-get install --only-upgrade linux

Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback