OVERVIEW CVE-2026-5958 is a race condition vulnerability in GNU sed that occurs when the utility is invoked with both the -i (in-place edit) and --follow-symlinks options enabled. The flaw stems from a non-atomic sequence of operations where sed resolves a symlink to its target, then separately opens the original symlink path. An attacker exploiting this race condition can atomically replace the symlink with a different target between these operations, causing sed to read content from an attacker-controlled source while writing the processed output to an unintended location. The vulnerability affects sed versions prior to 4.10. SEVERITY The attack requires local access and precise timing to exploit the race window between the two filesystem operations, making it moderately complex to execute reliably. The attack vector is local only, and the attacker must have the ability to manipulate symlinks on the target system. The potential impact is significant: an attacker can overwrite arbitrary files with attacker-controlled content in the context of the sed process, potentially achieving privilege escalation or system compromise depending on file permissions and sed's execution context. EXPLOITATION STATUS There is no indication of active exploitation in the wild, as the vulnerability is not listed on the CISA Known Exploited Vulnerabilities catalog. No public exploit code has been reported or widely distributed. Community attention appears minimal, reflected in the low EPSS score of 0.000040 and FAUCET risk score of 24.0 out of 100. Users running sed version 4.10 or later are protected from this vulnerability.
| Vendor | Product | Version(s) | CPE |
|---|---|---|---|
>= 4.1e, < 4.10CPE match | cpe:2.3:a:gnu:sed:*:*:*:*:*:*:*:* |
CVSS version used by this source: 4.0
CVSS:4.0/AV:L/AC:L/AT:P/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
The average CVE in this peer group has 0.0 Twitter, 0.0 Reddit, 0.0 Bluesky, 0.0 Mastodon, and 0.6 GitHub mentions.
The average CVE in this peer group has 0.0 InfoSec Media, 0.0 Vendor Blog, and 0.0 Security Researcher mentions.