Skip to main content

Linux Kernel CVE-2024-26737

HIGH
Use After Free (CWE-416)
2024-04-03 416baaa9-dc9f-4396-8d5f-8c081fb06d67
7.8
CVSS 3.1 · Vendor: 416baaa9-dc9f-4396-8d5f-8c081fb06d67
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Obtain local user account on target system
  2. Delivery
    Load BPF program using bpf_timer_* helpers
  3. Exploit
    Race bpf_timer_cancel against bpf_timer_cancel_and_free on shared timer object
  4. Execution
    Win narrow race window to trigger UAF on freed hrtimer
  5. Persist
    Exploit kernel heap corruption
  6. Impact
    Escalate to root privileges

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Memory lifecycle management
MITRE ATT&CK

2 techniques across 2 tactics: Execution, Privilege Escalation

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires a local user account with the ability to load BPF programs that use bpf_timer_* helpers. On Linux systems where kernel.unprivileged_bpf_disabled=0 (the default on many distributions including older Ubuntu and Debian releases), any unprivileged local user can load BPF programs and is therefore within scope. The attacker must control two concurrent execution paths that both reference the same bpf_hrtimer object - achievable from a single BPF program by orchestrating parallel operations across CPU cores. The race window itself imposes a practical constraint: reliable triggering requires repeated attempts and knowledge of kernel scheduler behavior to align the competing code paths. Remote exploitation is categorically excluded by the local attack vector (AV:L). Configuring kernel.unprivileged_bpf_disabled=1 limits exploitation to root-level or CAP_BPF-privileged processes, significantly narrowing the realistic attacker population.

Impact

The CVSS 3.1 score of 7.8 with vector AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H reflects a locally exploitable kernel UAF with theoretically high impact. NVD's AC:L assessment implies the race is easily triggered, but practical kernel race condition exploitation typically requires careful concurrency manipulation and heap spray techniques, suggesting real-world complexity is higher than AC:L implies. The EPSS score of 0.24% at the 15th percentile strongly contradicts elevated urgency - this vulnerability has seen minimal exploitation interest in the ecosystem. It does not appear in CISA KEV, and no POC has been identified. The realistic risk profile is moderate: a genuine kernel memory safety defect warranting patching on a routine schedule, but not an emergency response priority absent active exploitation signals. CVSS S:U (no scope change) is consistent with local kernel heap corruption without automatic lateral movement.

Exploit ScenarioDerived

A local attacker with a standard user account on a Linux system where unprivileged BPF is enabled loads a BPF program that creates a timer, then spawns two concurrent threads: one repeatedly calling bpf_timer_cancel and another calling the path that triggers bpf_timer_cancel_and_free on the same timer object. When the race window is won across CPU cores, the hrtimer struct is accessed after being freed, enabling kernel heap memory corruption that can be chained into a local privilege escalation to root. No public POC has been identified at time of analysis, so this would require custom kernel exploit development.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.9).
Patch available 0.2% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv2 – Aug 04, 2026

Use-after-free in the Linux kernel BPF timer subsystem allows a local attacker with low privileges to corrupt kernel heap memory through a race condition between bpf_timer_cancel and bpf_timer_cancel_and_free, potentially achieving full privilege escalation. The race occurs when bpf_timer_cancel_and_free nullifies and frees the timer pointer while bpf_timer_cancel still holds a stale reference, leading to hrtimer dereference on freed memory. No public exploit has been identified at time of analysis, and EPSS sits at 0.24% (15th percentile), indicating limited exploitation interest despite the high CVSS 7.8 score; this is not listed in CISA KEV.

Earlier versions of this analysis (1)
v1 Aug 04, 2026 - 13:41 cvss changed CVSS 7.8

Use-after-free in the Linux kernel BPF timer subsystem exposes local attackers with low privileges to kernel memory corruption, information disclosure, and potential privilege escalation. The flaw arises from a race between bpf_timer_cancel and bpf_timer_cancel_and_free: both acquire a pointer to the bpf_hrtimer struct under a spinlock, but the free path nulls timer->timer and calls kfree() before the cancel path finishes using its dangling copy. No active exploitation is confirmed (not in CISA KEV), no public exploit code has been identified, and EPSS sits at 0.24% (15th percentile), reflecting the tight race window and privilege requirements that limit real-world weaponization.

RemediationAI

Apply the upstream stable-tree patches referenced in the five kernel git commits linked in the NVD references. Linux distribution maintainers (Red Hat, Ubuntu, Debian, SUSE, and others) will backport these fixes into their respective kernel packages - apply vendor-released kernel updates as soon as they become available for your distribution. As an immediate compensating control where patching is not yet possible, set /proc/sys/kernel/unprivileged_bpf_disabled=1 (or the equivalent sysctl kernel.unprivileged_bpf_disabled=1 in /etc/sysctl.conf) to restrict BPF program loading to privileged processes only, directly eliminating the attack surface for unprivileged local users; note this may break unprivileged observability tools relying on eBPF. Systems that do not require BPF at all can consider building with CONFIG_BPF_SYSCALL disabled as a long-term hardening measure, though this impacts a wide range of kernel tracing and networking features.

Affects your stack

Find out whether the stacks and servers you run are on an affected version.

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

The vulnerability exists in the Linux kernel BPF subsystem within kernel/bpf/helpers.c, affecting the bpf_hrtimer internal structure used by BPF programs that leverage the bpf_timer_* helper API. CWE-416 (Use After Free) is the root cause: bpf_timer_cancel reads timer->timer under a spin lock into a local pointer 't', then releases the lock. Concurrently, bpf_timer_cancel_and_free acquires the same lock, sets timer->timer to NULL, releases the lock, calls hrtimer_cancel, and then kfree(t). When bpf_timer_cancel subsequently calls hrtimer_cancel(&t->timer), it dereferences already-freed kernel memory. The fix defers kfree via RCU grace period (kfree_rcu) in bpf_timer_cancel_and_free and wraps bpf_timer_cancel's timer->timer access in rcu_read_lock/unlock, ensuring the object cannot be freed while the read side holds the RCU lock. CPE data confirms affected versions span multiple stable Linux kernel branches and explicitly include 6.8-rc1 through 6.8-rc5.

Know when the next one hits your stack

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (416baaa9-dc9f-4396-8d5f-8c081fb06d67) PRIMARY 7.8 HIGH
AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
vuln.today AI 7.0 HIGH

AC:H because reliable race condition exploitation requires precise cross-CPU timing beyond attacker control; PR:L reflects minimum BPF access; AV:L confirmed by kernel-local execution context.

3.1 AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H
4.0 AV:L/AC:H/AT:P/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

Primary rating from Vendor (416baaa9-dc9f-4396-8d5f-8c081fb06d67).

CVSS VectorVendor: 416baaa9-dc9f-4396-8d5f-8c081fb06d67

Attack Vector
Local
Attack Complexity
Low
Privileges Required
Low
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High

Lifecycle Timeline

5
Analysis Updated
Aug 04, 2026 - 13:42 vuln.today
v2 - CVSS changed
Analysis Updated
Aug 04, 2026 - 13:41 vuln.today
v1 - CVSS changed
Severity Changed
Aug 04, 2026 - 11:23 NVD
MEDIUM HIGH
CVSS changed
Aug 04, 2026 - 11:23 NVD
5.5 (MEDIUM) 7.8 (HIGH)
CVE Published
Apr 03, 2024 - 17:15 cve.org
MEDIUM 5.5

DescriptionCVE.org

In the Linux kernel, the following vulnerability has been resolved:

bpf: Fix racing between bpf_timer_cancel_and_free and bpf_timer_cancel

The following race is possible between bpf_timer_cancel_and_free and bpf_timer_cancel. It will lead a UAF on the timer->timer.

bpf_timer_cancel(); spin_lock(); t = timer->time; spin_unlock();

bpf_timer_cancel_and_free(); spin_lock(); t = timer->timer; timer->timer = NULL; spin_unlock(); hrtimer_cancel(&t->timer); kfree(t);

/* UAF on t */ hrtimer_cancel(&t->timer);

In bpf_timer_cancel_and_free, this patch frees the timer->timer after a rcu grace period. This requires a rcu_head addition to the "struct bpf_hrtimer". Another kfree(t) happens in bpf_timer_init, this does not need a kfree_rcu because it is still under the spin_lock and timer->timer has not been visible by others yet.

In bpf_timer_cancel, rcu_read_lock() is added because this helper can be used in a non rcu critical section context (e.g. from a sleepable bpf prog). Other timer->timer usages in helpers.c have been audited, bpf_timer_cancel() is the only place where timer->timer is used outside of the spin_lock.

Another solution considered is to mark a t->flag in bpf_timer_cancel and clear it after hrtimer_cancel() is done. In bpf_timer_cancel_and_free, it busy waits for the flag to be cleared before kfree(t). This patch goes with a straight forward solution and frees timer->timer after a rcu grace period.

Executive ViewAI

Why It Matters

CVE-2024-26737 in the Linux kernel BPF timer subsystem creates a privilege escalation risk that allows local users to gain root-level access through a race condition, potentially compromising systems organization-wide. This affects all Linux-based infrastructure including servers, containers, and development systems, enabling attackers with initial access to elevate privileges and move laterally within your environment. Although current exploitation activity remains minimal, the severity of full privilege escalation warrants prioritized patching to preserve system integrity and access controls.

Business Impact: High
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.2%
Top 85% exploitable
Prevalence
Ubiquitous
core OS kernel present in virtually all Linux deployments globally
Data Quality
3 sources
Confidence: Low

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity HIGH
CISA KEV No
Public POC No
EPSS 0.2%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Small
Automatable· derived
No
Human Impact
High

Priority Score

39
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +39
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Use-after-free vulnerabilities occur when a program continues to access memory through a pointer after that memory has been deallocated.

Memory corruption occurs when a program writes data beyond the boundaries of allocated memory regions or accesses memory in unintended ways, violating the integrity of the process's address space.

Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.

Affected Products (CPE)CVE.org

cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:6.8:rc1:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:6.8:rc2:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:6.8:rc3:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:6.8:rc4:*:*:*:*:*:*
cpe:2.3:o:linux:linux_kernel:6.8:rc5:*:*:*:*:*:*

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy