Undefined Behavior in Linux Kernel's bpftool: Vulnerability in Linux Package

linux Updated 02 Oct 2025

Summary

21/10/2024
N/A
Yes i
Unrated
Not published

DEBIAN-CVE-2024-49987: In the Linux kernel, the following vulnerability has been resolved: bpftool: Fix undefined behavior in qsort(NULL, 0, ...) When netfilter has no entry to display, qsort is called with qsort(NULL, 0, ...). Affects linux versions < 6.11.4-1. Fixed in 6.11.4-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 Penetration testing for web, API and mobile Manual testing by engineers who build software, not an auditor's checklist. Trusted by teams at Swift and Google Talk to Devnack

Background

The Linux package is a core component of the Debian operating system, providing the essential kernel that manages system resources and hardware interactions. It is widely used across various distributions and is known for its stability and performance. The Linux kernel supports a wide range of functionalities, including process management, memory management, and networking. However, it is susceptible to vulnerabilities that can lead to undefined behavior, as seen in this specific issue with bpftool.

Vulnerability Detail

In the Linux kernel, a vulnerability has been identified in bpftool where the function qsort is called with a NULL pointer when there are no netfilter entries to display. This results in undefined behavior, as the C standard indicates that passing a NULL pointer to functions expecting valid pointers can lead to unpredictable outcomes. The specific error reported by UBSan indicates that a null pointer was passed as an argument, which is not permissible. This vulnerability could potentially lead to crashes or unexpected behavior in applications relying on netfilter.

How To Fix

Minimum fixed version

6.11.4-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. However, users can avoid triggering the issue by ensuring that netfilter has valid entries before invoking functions that rely on qsort.

Conclusion

The vulnerability in the Linux kernel's bpftool highlights the importance of maintaining updated software to prevent undefined behavior that can lead to system instability. Users are encouraged to apply the available patch and monitor their systems for vulnerabilities.

See every vulnerability recorded for linux →

Share this vulnerability

FAQ

The vulnerability involves undefined behavior when qsort is called with a NULL pointer in the Linux kernel's bpftool.

It can lead to crashes or unpredictable behavior in applications that utilize netfilter, potentially impacting system stability.

Yes, the vulnerability has been fixed in the Linux package version 6.11.4-1 and users are advised to update.

While there are no specific workarounds, ensuring valid entries in netfilter can help avoid triggering the vulnerability.

You can use Vulert, which monitors and alerts for open-source vulnerabilities in your software using a manifest file like package-lock.json. You can check if your application is affected by this vulnerability using the Vulert playground without any signup.

Related vulnerabilities

Recent vulnerabilities recorded for linux.

How To Fix

Minimum fixed version

6.11.4-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