CVE-2026-139214 perf: Fix UAF in attach_task_ctx_data()

Published Updated

CVSS score

High

7.8/10

CVSS 3.1 · Scored by the Linux kernel CNA Breakdown
Exploited in the wild
Not known
Not in CISA's KEV catalogue
Exploit code
None known
No public exploit found
Fix
Available
See affected versions
Attack path
Local or same network
Any signed-in user, no user action

What is CVE-2026-139214?

CVE-2026-139214 is a high-severity vulnerability in Linux, published on 30 Nov 2026.

Official description

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

perf: Fix UAF in attach_task_ctx_data()

struct perf_ctx_data is RCU protected. In attach_task_ctx_data(), the cmpxchg retry loop runs without holding rcu_read_lock(). If task->perf_ctx_data already holds a pointer (call it `cd1`), then try_cmpxchg(&task->perf_ctx_data, &old, cd) fails and loads old = cd1. A concurrent thread running detach_task_ctx_data() could free cd1 leading to UAF and further memory corruption when cd1 is reclaimed by another thread.

CPU 0: attach_task_ctx_data() CPU 1: detach_task_ctx_data() ----------------------------- ----------------------------- try_cmpxchg(&task->perf_ctx_data, &old, cd2) -> fails; loads old = cd1

refcount_dec_and_test(&cd1->refcount) try_cmpxchg(&task->perf_ctx_data, &cd1, NULL) perf_free_ctx_data_rcu(cd1) [ RCU grace period -> kfree(cd1) ]

refcount_inc_not_zero(&old->refcount) -> UAF on freed cd1

Fix this by taking rcu_read_lock across the race window.

How severe is CVE-2026-139214?

CVE-2026-139214 scores 7.8 out of 10 under CVSS 3.1, which is high severity. It was scored by the Linux kernel CNA.

Attack vector
Local
Attack complexity
Low
Privileges required
Low
User interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High

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

Which versions are affected by CVE-2026-139214?

How do I fix CVE-2026-139214?

Upgrade to a fixed version.

Is CVE-2026-139214 being exploited?

There is no known exploitation of CVE-2026-139214 in the wild and no public exploit code.

Sources

Also known as BELL-CVE-2026-139214, DEBIAN-CVE-2026-139214, GHSA-mm9r-fr8x-j39r, UBUNTU-CVE-2026-139214.

Is CVE-2026-139214 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free