Double Uncharge Memory Vulnerability in Kernel

Kernel Updated 02 Oct 2025

Summary

24/04/2022
N/A
No i
Unrated
Not published

GSD-2022-1002077: bpf, sockmap: Fix double uncharge the mem of sk_msg. Affects Kernel versions >= 604326b41a6fb9b4a78b6179335decee0365cd8c, < cd84ea3920aef936c559b63099ef0013ce6b2325. No fix is published. 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 Kernel is a critical component of the Linux operating system that manages system resources and facilitates communication between hardware and software. It provides essential functionalities such as process management, memory management, and device drivers. The vulnerability in question affects the Kernel's bpf and sockmap modules, which are responsible for handling network socket operations and implementing Berkeley Packet Filter (BPF) programs. These modules allow users to create and manage socket maps, which can be used for various network-related tasks.

Vulnerability Detail

The double uncharge memory vulnerability in the bpf and sockmap modules of the Kernel allows an attacker to exploit a flaw in the handling of sk_msg objects. This vulnerability can be triggered by a specially crafted network packet, leading to a double free of memory. If successfully exploited, an attacker could potentially execute arbitrary code or cause a denial-of-service (DoS) condition. The vulnerability was introduced in version 4.20 of the Kernel and has been fixed in version 5.10.110.

How To Fix

No fixed version is published for this vulnerability.

Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. Scan free →

Workaround

As a workaround, users can apply the patch provided in the fix commit (cd84ea3920aef936c559b63099ef0013ce6b2325) manually. The patch modifies the affected code to prevent the double uncharge of sk_msg memory. Here is an example of the modified code:

// Original code
...
free_sk_msg(msg);
...

// Patched code
...
if (msg->sk)
  free_sk_msg(msg);
...

Conclusion

The double uncharge memory vulnerability in the bpf and sockmap modules of the Kernel can pose a significant security risk if left unpatched. It is crucial to update the Linux Kernel to version 5.10.110 or later to mitigate this vulnerability. Regularly updating the Kernel and staying informed about the latest security patches is essential for maintaining a secure system. For further support or assistance with vulnerability remediation, you can reach out to DevNack.com.

See every vulnerability recorded for Kernel →

Share this vulnerability

FAQ

If successfully exploited, this vulnerability could allow an attacker to execute arbitrary code or cause a denial-of-service (DoS) condition on a system running the affected version of the Kernel.

You can use the Vulert Playground (https://vulert.com/scanner) to check if your system is affected by this vulnerability. Simply upload your package-lock.json file and the Vulert Playground will analyze it for any open-source vulnerabilities, including this one.

There are no known instances of this vulnerability being exploited in the wild at the time of this report. However, it is important to apply the necessary updates and patches to mitigate the risk.

Yes, this vulnerability can be exploited remotely by sending a specially crafted network packet to a system running the affected version of the Kernel.

For more details about this vulnerability, including the technical aspects and the fix commit, you can refer to the vulnerability report in the GSD database (https://github.com/cloudsecurityalliance/gsd-database/blob/main/2022/1002xxx/GSD-2022-1002077.json).

Related vulnerabilities

Recent vulnerabilities recorded for Kernel.

How To Fix

No fixed version is published for this vulnerability.

Tip — Not sure whether your app is affected? Vulert can check the versions your app actually runs. 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