CVE-2026-140038Binutils: gprofng uses predictable /tmp directory with unchecked mkdir() enabling symlink-based file clobber
- 5.1MediumCVSS base score
- —Exploitation in 30 daysno EPSS score yet
- NoKnown exploitednot in CISA's KEV catalog
- NonePublic exploitsnone known yet
Description
A flaw was found in the gprofng component of binutils. The utility creates temporary directories in shared locations using predictable names based on user and process identifiers without verifying whether the directory already exists. A local attacker can exploit this flaw by pre-creating the expected directory and placing symbolic links inside it, causing a victim's process to overwrite or truncate arbitrary files writable by that victim.
Timeline
ID reserved
By redhat
- 1 day later
· 1 day later
Published
Changes after publication (a new score, a public exploit, EPSS crossing 1, 10 or 50 %, leaving KEV) are kept since November 2026; earlier ones are not known.
Scores
| Scored by | CVSS | Score | Vector |
|---|---|---|---|
| redhatCNA (assigner) | 3.1 | Medium5.1 | CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:L |
| NVDNVD · Awaiting Analysis | 3.1 | Medium5.1 | CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:L |
- EPSS (exploitation in 30 days)
- Not scored
The list uses the assigner's score when there is one, then CISA's, then NVD's: Medium 5.1.
Affected products
Red Hat · Red Hat Enterprise Linux 10
All versions: affected
Red Hat · Red Hat Enterprise Linux 10
All versions: affected
Red Hat · Red Hat Enterprise Linux 10
All versions: affected
Red Hat · Red Hat Enterprise Linux 10
All versions: affected
Red Hat · Red Hat Enterprise Linux 10
All versions: affected
Red Hat · Red Hat Enterprise Linux 6
All versions: affected
Red Hat · Red Hat Enterprise Linux 7
All versions: affected
Red Hat · Red Hat Enterprise Linux 7
All versions: affected
Red Hat · Red Hat Enterprise Linux 8
All versions: affected
Red Hat · Red Hat Enterprise Linux 8
All versions: affected
Red Hat · Red Hat Enterprise Linux 8
All versions: affected
Red Hat · Red Hat Enterprise Linux 8
All versions: affected
Red Hat · Red Hat Enterprise Linux 8
All versions: affected
Red Hat · Red Hat Enterprise Linux 8
All versions: affected
Red Hat · Red Hat Enterprise Linux 8
All versions: affected
Red Hat · Red Hat Enterprise Linux 9
All versions: affected
Red Hat · Red Hat Enterprise Linux 9
All versions: affected
Red Hat · Red Hat Enterprise Linux 9
All versions: affected
Red Hat · Red Hat Enterprise Linux 9
All versions: affected
Red Hat · Red Hat Enterprise Linux 9
All versions: affected
Red Hat · Red Hat Hardened Images
All versions: affected
Red Hat · Red Hat OpenShift Container Platform 4
All versions: affected
Red Hat · Red Hat OpenShift Container Platform 4
All versions: affected
Red Hat · Red Hat OpenShift Container Platform 5
All versions: affected
Red Hat · Red Hat OpenShift Container Platform 5
All versions: affected
What to do
Workaround: Isolate execution environments to prevent shared temporary file access, or restrict profiling activities on shared hosts: 1. Execute gprofng workflows within an isolated container (such as via Podman) or a dedicated mount namespace with a private /tmp filesystem, preventing other local users from pre-creating predictable temporary paths. 2. Avoid running gprofng analysis sessions on multi-user systems where untrusted local accounts have access to the shared /tmp directory. Caveats: Running profiling tools inside an isolated container or private namespace may restrict visibility into processes or hardware performance counters on the host system without granting additional container capabilities.
References
References2
- https://access.redhat.com/security/cve/CVE-2026-140038 (opens in a new tab)vdb-entryx_refsource_REDHAT
- RHBZ#2465392 (opens in a new tab)issue-trackingx_refsource_REDHAT
Sources
The same CVE in the primary databases and aggregators, to check against.
- CVE.org record (opens in a new tab)
- CVE List JSON (GitHub) (opens in a new tab)
- NVD (opens in a new tab)
- FIRST EPSS (opens in a new tab)
- EUVD EUVD-2026-139826 (opens in a new tab)
- OSV.dev (opens in a new tab)
- GitHub Advisories (opens in a new tab)
- CIRCL Vulnerability-Lookup (opens in a new tab)
Badge for a README or a ticket
[](https://cveledger.app/cve/CVE-2026-140038)Record last updated .