CVE-2026-139318

Source
https://cve.org/CVERecord?id=CVE-2026-139318
Import Source
https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-139318.json
JSON Data
https://api.osv.dev/v1/vulns/CVE-2026-139318
Downstream
Published
2026-11-30T13:33:39Z
Modified
2026-11-30T15:01:40Z
Summary
bpf: Read the probe of a perf event under event_mutex
Details

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

bpf: Read the probe of a perf event under event_mutex

For a perf event on a kprobe or uprobe event which was made in tracefs, bpf_get_kprobe_info() and bpf_get_uprobe_info() look the probe up by name in the list of dynamic events, and hand a pointer to its symbol or file name back to the caller. None of the callers holds event_mutex.

The perf event keeps its trace event alive, nothing else. Other dynamic events are removed from the list and freed during the walk. And a probe which shares its event with other probes can be deleted while the event is in use, so even the probe which is found can be freed, together with the string, before the caller has measured and copied it. The result is a use-after-free in the walk, in strlen() and in the copy to user space, or a NULL pointer dereference.

The readers are BPF_OBJ_GET_INFO_BY_FD and fdinfo of a perf link, for whoever holds a descriptor of the link, and BPF_TASK_FD_QUERY. The other side is anybody who may write to dynamic_events, kprobe_events or uprobe_events.

Take event_mutex in bpf_get_perf_event_info() and give the caller a copy of the name, which it has to free.

Database specific
{
    "cna_assigner":  "Linux",
    "osv_generated_from":  "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/139xxx/CVE-2026-139318.json"
}
References

Affected packages

Git / git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git

Affected ranges

Type
GIT
Repo
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
Events
Introduced
41bdc4b40ed6fb26c6acc655ed9a243a348709c9
Fixed
e1b668adaa02c6f45f0d68b466aacb854e6b473c
Fixed
f5d96a5f4aea1fcd9b4093f274715c052bf7715c
Fixed
fd3e7631fb502f6b51dc25e4724acc836683145d
Fixed
be367c0bf210854265cf6b6dcaf74c5ad632978c
Fixed
3ccd700543f16a2b2ab656f35dcaeb6bd7c45e22

Database specific

source
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-139318.json"

Linux / Kernel

Package

Name
Kernel

Affected ranges

Type
ECOSYSTEM
Events
Introduced
4.18.0
Fixed
6.6.163
Type
ECOSYSTEM
Events
Introduced
6.7.0
Fixed
6.12.119
Type
ECOSYSTEM
Events
Introduced
6.13.0
Fixed
6.18.65
Type
ECOSYSTEM
Events
Introduced
6.19.0
Fixed
7.3.6

Database specific

source
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-139318.json"