CVE & CISA-KEV Catalog

CVE-2024-58060

HIGH
7.8
CVSS v3
NVD

Description

In the Linux kernel, the following vulnerability has been resolved: bpf: Reject struct_ops registration that uses module ptr and the module btf_id is missing There is a UAF report in the bpf_struct_ops when CONFIG_MODULES=n. In particular, the report is on tcp_congestion_ops that has a "struct module *owner" member. For struct_ops that has a "struct module *owner" member, it can be extended either by the regular kernel module or by the bpf_struct_ops. bpf_try_module_get() will be used to do the refcounting and different refcount is done based on the owner pointer. When CONFIG_MODULES=n, the btf_id of the "struct module" is missing: WARN: resolve_btfids: unresolved symbol module Thus, the bpf_try_module_get() cannot do the correct refcounting. Not all subsystem's struct_ops requires the "struct module *owner" member. e.g. the recent sched_ext_ops. This patch is to disable bpf_struct_ops registration if the struct_ops has the "struct module *" member and the "struct module" btf_id is missing. The btf_type_is_fwd() helper is moved to the btf.h header file for this test. This has happened since the beginning of bpf_struct_ops which has gone through many changes. The Fixes tag is set to a recent commit that this patch can apply cleanly. Considering CONFIG_MODULES=n is not common and the age of the issue, targeting for bpf-next also.

How to fix

Remediation Available
linuxDebian
Fixed in:6.12.13-1CVE-2024-58060
Fixed in:6.12.13-1CVE-2024-58060
linux-azure-6.11Ubuntu
Fixed in:6.11.0-1015.15~24.04.1USN-7521-1
linux-gcp-6.11Ubuntu
Fixed in:6.11.0-1015.15~24.04.1USN-7521-1
linux-hwe-6.11Ubuntu
Fixed in:6.11.0-26.26~24.04.1USN-7521-1
linux-image-6.11.0-1014-lowlatencyUbuntu
Fixed in:6.11.0-1014.15~24.04.1USN-7521-3
linux-image-6.11.0-1014-lowlatency-64kUbuntu
Fixed in:6.11.0-1014.15~24.04.1USN-7521-3
linux-image-6.11.0-1015-azureUbuntu
Fixed in:6.11.0-1015.15~24.04.1USN-7521-1
linux-image-6.11.0-1015-azure-fdeUbuntu
Fixed in:6.11.0-1015.15~24.04.1USN-7521-1
linux-image-6.11.0-1015-gcpUbuntu
Fixed in:6.11.0-1015.15~24.04.1USN-7521-1
linux-image-6.11.0-1015-gcp-64kUbuntu
Fixed in:6.11.0-1015.15~24.04.1USN-7521-1
linux-image-6.11.0-1022-oemUbuntu
Fixed in:6.11.0-1022.22USN-7521-1
linux-image-6.11.0-26-genericUbuntu
Fixed in:6.11.0-26.26~24.04.1USN-7521-1
linux-image-6.11.0-26-generic-64kUbuntu
Fixed in:6.11.0-26.26~24.04.1USN-7521-1
linux-image-azureUbuntu
Fixed in:6.11.0-1015.15~24.04.1USN-7521-1
linux-image-azure-fdeUbuntu
Fixed in:6.11.0-1015.15~24.04.1USN-7521-1
linux-image-gcpUbuntu
Fixed in:6.11.0-1015.15~24.04.1USN-7521-1
linux-image-gcp-64kUbuntu
Fixed in:6.11.0-1015.15~24.04.1USN-7521-1
linux-image-generic-64k-hwe-24.04Ubuntu
Fixed in:6.11.0-26.26~24.04.1USN-7521-1
linux-image-generic-hwe-24.04Ubuntu
Fixed in:6.11.0-26.26~24.04.1USN-7521-1
linux-image-lowlatency-64k-hwe-24.04Ubuntu
Fixed in:6.11.0-1014.15~24.04.1USN-7521-3
linux-image-lowlatency-hwe-24.04Ubuntu
Fixed in:6.11.0-1014.15~24.04.1USN-7521-3
linux-image-oem-24.04bUbuntu
Fixed in:6.11.0-1022.22USN-7521-1
linux-image-virtual-hwe-24.04Ubuntu
Fixed in:6.11.0-26.26~24.04.1USN-7521-1
linux-lowlatency-hwe-6.11Ubuntu
Fixed in:6.11.0-1014.15~24.04.1USN-7521-3
linux-oem-6.11Ubuntu
Fixed in:6.11.0-1022.22USN-7521-1

Remediation is compiled from vendor and distribution security advisories. Always confirm against the linked source for your exact version and platform.

CVSS v3 Vector

Exploitability

Attack VectorLocal
Attack ComplexityLow
Privileges RequiredLow
User InteractionNone
ScopeUnchanged

Impact

ConfidentialityHigh
IntegrityHigh
AvailabilityHigh

CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

Exploit Intelligence

0.19%probability of exploitation in 30 days
9thpercentile

Low risk: more likely to be exploited than 9% of all known CVEs.

References

Related Vulnerabilities

Other CWE-416 (Use After Free) vulnerabilities, ordered by exploit likelihood. View all

CVESeverityCVSSEPSSExploitedFix
CVE-2019-0708Critical9.8100%KEV + Ransom-
CVE-2021-31166Critical9.8100%KEVFix
CVE-2015-5119Critical9.899%KEV-
CVE-2010-3962High8.197%KEV-
CVE-2015-0313Critical9.896%KEVFix
CVE-2017-9798High7.595%-Fix
Embed a live status badge for CVE-2024-58060
CVE-2024-58060 severity badge

Markdown

[![CVE-2024-58060](https://tridentstack.com/cve/badge/CVE-2024-58060.svg)](https://tridentstack.com/cve/CVE-2024-58060)

HTML

<a href="https://tridentstack.com/cve/CVE-2024-58060"><img src="https://tridentstack.com/cve/badge/CVE-2024-58060.svg" alt="CVE-2024-58060"></a>

Find and fix vulnerabilities across your fleet

TridentStack Control continuously scans your Windows, macOS, and Linux fleet for known vulnerabilities, prioritizes them by severity and active exploitation, and patches them automatically.

Start free

This product uses NVD data but is not endorsed or certified by the NVD. EPSS scores courtesy of FIRST.org (https://www.first.org/epss). Source: CISA KEV Catalog. Data as of 2025-03-21.