{"id":"CVE-2026-5958","aliases":["AZL-83102","DEBIAN-CVE-2026-5958","EUVD-2026-23834","GHSA-9r7w-j29g-xqx8","JLSEC-2026-213","MGASA-2026-0128","OESA-2026-2281","OESA-2026-2282","OESA-2026-2283","OESA-2026-2284","OESA-2026-2478","RHSA-2026:10995","SUSE-SU-2026:1659-1","SUSE-SU-2026:1699-1","SUSE-SU-2026:1941-1","SUSE-SU-2026:21413-1","SUSE-SU-2026:21448-1","SUSE-SU-2026:22256-1","SUSE-SU-2026:22325-1","UBUNTU-CVE-2026-5958","USN-8229-1","USN-8229-2","openSUSE-SU-2026:10649-1","openSUSE-SU-2026:21024-1"],"status":"published","title":"Race Condition in GNU Sed","description":"When sed is invoked with both -i (in-place edit) and --follow-symlinks, the function open_next_file() performs two separate, non-atomic filesystem operations on the same path: \n1. resolves symlink to its target and stores the resolved path for determining when output is written,\n2. opens the original symlink path (not the resolved one) to read the file. \nBetween these two calls there is a race window. If an attacker atomically replaces the symlink with a different target during that window, sed will: read content from the new (attacker-chosen) symlink target and write the processed result to the path recorded in step 1. This can lead to arbitrary file overwrite with attacker-controlled content in the context of the sed process.\n\n\nThis issue was fixed in version 4.10.","severity":{"version":"4.0","score":2.1,"vector":"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","level":"low","assessor":"cna","from":"cve"},"epss":{"day":"2026-11-10","score":0.00142,"percentile":0.03551,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":true},"cwes":["CWE-367"],"published":"2026-04-19T00:00:00Z","modified":"2026-11-05T05:40:51Z","fixes":[{"ecosystem":"Azure Linux:3","package":"sed","fixed_in":["4.9-2"],"sources":["osv"]},{"ecosystem":"Debian:12","package":"sed","fixed_in":["4.9-1+deb12u1"],"sources":["osv"]},{"ecosystem":"Debian:13","package":"sed","fixed_in":["4.9-2+deb13u1"],"sources":["osv"]},{"ecosystem":"Debian:14","package":"sed","fixed_in":["4.9-3"],"sources":["osv"]},{"ecosystem":"Julia","package":"sed_jll","fixed_in":["4.10.0+0"],"sources":["osv"]},{"ecosystem":"Mageia:9","package":"sed","fixed_in":["4.9-1.1.mga9"],"sources":["osv"]},{"ecosystem":"openEuler:24.03-LTS-SP3","package":"sed","fixed_in":["4.9-5.oe2403sp3"],"sources":["osv"]},{"ecosystem":"openEuler:22.03-LTS-SP4","package":"sed","fixed_in":["4.8-8.oe2203sp4"],"sources":["osv"]},{"ecosystem":"openEuler:24.03-LTS","package":"sed","fixed_in":["4.9-5.oe2403"],"sources":["osv"]},{"ecosystem":"openEuler:24.03-LTS-SP1","package":"sed","fixed_in":["4.9-5.oe2403sp1"],"sources":["osv"]},{"ecosystem":"openEuler:20.03-LTS-SP4","package":"sed","fixed_in":["4.8-8.oe2003sp4"],"sources":["osv"]},{"ecosystem":"Red Hat:hummingbird:1","package":"sed","fixed_in":["0:4.10-1.hum1"],"sources":["osv"]},{"ecosystem":"SUSE:Linux Micro 6.2","package":"sed","fixed_in":["4.9-160000.3.1"],"sources":["osv"]},{"ecosystem":"SUSE:Linux Enterprise Server 16.0","package":"sed","fixed_in":["4.9-160000.3.1"],"sources":["osv"]},{"ecosystem":"SUSE:Linux Enterprise Server for SAP applications 16.0","package":"sed","fixed_in":["4.9-160000.3.1"],"sources":["osv"]},{"ecosystem":"Ubuntu:Pro:18.04:LTS","package":"sed","fixed_in":["4.4-2ubuntu0.1~esm1"],"sources":["osv"]},{"ecosystem":"Ubuntu:Pro:20.04:LTS","package":"sed","fixed_in":["4.7-1ubuntu0.1~esm1"],"sources":["osv"]},{"ecosystem":"Ubuntu:22.04:LTS","package":"sed","fixed_in":["4.8-1ubuntu2.1"],"sources":["osv"]},{"ecosystem":"Ubuntu:24.04:LTS","package":"sed","fixed_in":["4.9-2ubuntu0.24.04.1"],"sources":["osv"]},{"ecosystem":"Ubuntu:25.10","package":"sed","fixed_in":["4.9-2ubuntu0.25.10.1"],"sources":["osv"]},{"ecosystem":"Ubuntu:26.04:LTS","package":"sed","fixed_in":["4.9-2ubuntu1"],"sources":["osv"]},{"ecosystem":"openSUSE:Tumbleweed","package":"sed","fixed_in":["4.10-1.1"],"sources":["osv"]},{"ecosystem":"openSUSE:Leap 16.0","package":"sed","fixed_in":["4.9-160000.3.1"],"sources":["osv"]}],"affected":[{"source":"osv","ecosystem":"Azure Linux:3","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.9-2"}]}]},{"source":"osv","ecosystem":"Debian:12","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.9-1+deb12u1"}]}],"versions":["4.9-1"]},{"source":"osv","ecosystem":"Debian:13","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.9-2+deb13u1"}]}],"versions":["4.9-2"]},{"source":"osv","ecosystem":"Debian:14","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.9-3"}]}],"versions":["4.9-2"]},{"source":"osv","ecosystem":"Julia","package":"sed_jll","ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"4.10.0+0"}]}]},{"source":"osv","ecosystem":"Mageia:9","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.9-1.1.mga9"}]}]},{"source":"osv","ecosystem":"openEuler:24.03-LTS-SP3","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.9-5.oe2403sp3"}]}]},{"source":"osv","ecosystem":"openEuler:22.03-LTS-SP4","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.8-8.oe2203sp4"}]}]},{"source":"osv","ecosystem":"openEuler:24.03-LTS","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.9-5.oe2403"}]}]},{"source":"osv","ecosystem":"openEuler:24.03-LTS-SP1","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.9-5.oe2403sp1"}]}]},{"source":"osv","ecosystem":"openEuler:20.03-LTS-SP4","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.8-8.oe2003sp4"}]}]},{"source":"osv","ecosystem":"Red Hat:hummingbird:1","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"0:4.10-1.hum1"}]}]},{"source":"osv","ecosystem":"SUSE:Linux Micro 6.2","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.9-160000.3.1"}]}]},{"source":"osv","ecosystem":"SUSE:Linux Enterprise Server 16.0","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.9-160000.3.1"}]}]},{"source":"osv","ecosystem":"SUSE:Linux Enterprise Server for SAP applications 16.0","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.9-160000.3.1"}]}]},{"source":"osv","ecosystem":"Ubuntu:Pro:18.04:LTS","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.4-2ubuntu0.1~esm1"}]}],"versions":["4.4-1","4.4-2"]},{"source":"osv","ecosystem":"Ubuntu:Pro:20.04:LTS","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.7-1ubuntu0.1~esm1"}]}],"versions":["4.7-1"]},{"source":"osv","ecosystem":"Ubuntu:22.04:LTS","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.8-1ubuntu2.1"}]}],"versions":["4.7-1ubuntu1","4.7-1ubuntu2","4.8-1ubuntu1","4.8-1ubuntu2"]},{"source":"osv","ecosystem":"Ubuntu:24.04:LTS","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.9-2ubuntu0.24.04.1"}]}],"versions":["4.9-1","4.9-2","4.9-2build1"]},{"source":"osv","ecosystem":"Ubuntu:25.10","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.9-2ubuntu0.25.10.1"}]}],"versions":["4.9-2build1","4.9-2build2"]},{"source":"osv","ecosystem":"Ubuntu:26.04:LTS","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.9-2ubuntu1"}]}],"versions":["4.9-2build2","4.9-2build3"]},{"source":"osv","ecosystem":"Ubuntu:22.04:LTS","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.8-1ubuntu2.1"}]}],"versions":["4.7-1ubuntu1","4.7-1ubuntu2","4.8-1ubuntu1","4.8-1ubuntu2"]},{"source":"osv","ecosystem":"Ubuntu:24.04:LTS","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.9-2ubuntu0.24.04.1"}]}],"versions":["4.9-1","4.9-2","4.9-2build1"]},{"source":"osv","ecosystem":"Ubuntu:25.10","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.9-2ubuntu0.25.10.1"}]}],"versions":["4.9-2build1","4.9-2build2"]},{"source":"osv","ecosystem":"Ubuntu:26.04:LTS","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.9-2ubuntu1"}]}],"versions":["4.9-2build2","4.9-2build3"]},{"source":"osv","ecosystem":"Ubuntu:Pro:18.04:LTS","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.4-2ubuntu0.1~esm1"}]}],"versions":["4.4-1","4.4-2"]},{"source":"osv","ecosystem":"Ubuntu:Pro:20.04:LTS","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.7-1ubuntu0.1~esm1"}]}],"versions":["4.7-1"]},{"source":"osv","ecosystem":"openSUSE:Tumbleweed","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.10-1.1"}]}]},{"source":"osv","ecosystem":"openSUSE:Leap 16.0","package":"sed","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"4.9-160000.3.1"}]}]}],"products":[{"vendor":"gnu","product":"sed"}],"references":[{"url":"https://www.gnu.org/software/sed/","tags":["product","web"]},{"url":"https://cert.pl/en/posts/2026/04/CVE-2026-5958","tags":["third-party-advisory","web"]},{"url":"http://www.openwall.com/lists/oss-security/2026/05/13/1","tags":["web"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-5958","tags":["web","advisory"]},{"url":"https://www.gnu.org/software/sed","tags":["web"]},{"url":"https://github.com/advisories/GHSA-9r7w-j29g-xqx8","tags":["web"]},{"url":"https://security-tracker.debian.org/tracker/CVE-2026-5958","tags":["advisory"]},{"url":"https://advisories.mageia.org/MGASA-2026-0128.html","tags":["advisory"]},{"url":"https://bugs.mageia.org/show_bug.cgi?id=35465","tags":["report"]},{"url":"https://lists.opensuse.org/archives/list/security-announce@lists.opensuse.org/message/242J2LW3C7C4MDLVKSD3DJDBKXAJXUTP/","tags":["web"]},{"url":"https://www.openeuler.org/zh/security/security-bulletins/detail/?id=openEuler-SA-2026-2281","tags":["advisory"]},{"url":"https://www.openeuler.org/zh/security/security-bulletins/detail/?id=openEuler-SA-2026-2282","tags":["advisory"]},{"url":"https://www.openeuler.org/zh/security/security-bulletins/detail/?id=openEuler-SA-2026-2283","tags":["advisory"]},{"url":"https://www.openeuler.org/zh/security/security-bulletins/detail/?id=openEuler-SA-2026-2284","tags":["advisory"]},{"url":"https://www.openeuler.org/zh/security/security-bulletins/detail/?id=openEuler-SA-2026-2478","tags":["advisory"]},{"url":"https://access.redhat.com/errata/RHSA-2026:10995","tags":["advisory"]},{"url":"https://images.redhat.com/","tags":["article"]},{"url":"https://access.redhat.com/security/cve/CVE-2026-5958","tags":["report"]},{"url":"https://access.redhat.com/security/updates/classification/","tags":["article"]},{"url":"https://security.access.redhat.com/data/csaf/v2/advisories/2026/rhsa-2026_10995.json","tags":["advisory"]},{"url":"https://bugzilla.redhat.com/show_bug.cgi?id=2458960","tags":["report"]},{"url":"https://www.cve.org/CVERecord?id=CVE-2026-5958","tags":["advisory","report"]},{"url":"https://www.suse.com/support/update/announcement/2026/suse-su-20261659-1/","tags":["advisory"]},{"url":"https://bugzilla.suse.com/1262144","tags":["report"]},{"url":"https://www.suse.com/security/cve/CVE-2026-5958","tags":["web"]},{"url":"https://www.suse.com/support/update/announcement/2026/suse-su-20261699-1/","tags":["advisory"]},{"url":"https://www.suse.com/support/update/announcement/2026/suse-su-20261941-1/","tags":["advisory"]},{"url":"https://www.suse.com/support/update/announcement/2026/suse-su-202621413-1/","tags":["advisory"]},{"url":"https://www.suse.com/support/update/announcement/2026/suse-su-202621448-1/","tags":["advisory"]},{"url":"https://www.suse.com/support/update/announcement/2026/suse-su-202622256-1/","tags":["advisory"]},{"url":"https://www.suse.com/support/update/announcement/2026/suse-su-202622325-1/","tags":["advisory"]},{"url":"https://ubuntu.com/security/CVE-2026-5958","tags":["report"]},{"url":"https://ubuntu.com/security/notices/USN-8229-1","tags":["advisory"]},{"url":"https://ubuntu.com/security/notices/USN-8229-2","tags":["advisory"]},{"url":"","tags":["advisory"]}],"sources":{"cve":[{"id":"CVE-2026-5958","title":"Race Condition in GNU Sed","description":"When sed is invoked with both -i (in-place edit) and --follow-symlinks, the function open_next_file() performs two separate, non-atomic filesystem operations on the same path: \n1. resolves symlink to its target and stores the resolved path for determining when output is written,\n2. opens the original symlink path (not the resolved one) to read the file. \nBetween these two calls there is a race window. If an attacker atomically replaces the symlink with a different target during that window, sed will: read content from the new (attacker-chosen) symlink target and write the processed result to the path recorded in step 1. This can lead to arbitrary file overwrite with attacker-controlled content in the context of the sed process.\n\n\nThis issue was fixed in version 4.10.","status":"published","published":"2026-04-20T11:59:32.214Z","modified":"2026-05-13T05:17:46.051Z","cvss":[{"version":"4.0","score":2.1,"vector":"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","level":"low","assessor":"cna"}],"cwes":["CWE-367"],"updated_at":"2026-11-02T13:39:27.849196Z"}],"euvd":[{"id":"EUVD-2026-23834","description":"When sed is invoked with both -i (in-place edit) and --follow-symlinks, the function open_next_file() performs two separate, non-atomic filesystem operations on the same path: \n1. resolves symlink to its target and stores the resolved path for determining when output is written,\n2. opens the original symlink path (not the resolved one) to read the file. \nBetween these two calls there is a race window. If an attacker atomically replaces the symlink with a different target during that window, sed will: read content from the new (attacker-chosen) symlink target and write the processed result to the path recorded in step 1. This can lead to arbitrary file overwrite with attacker-controlled content in the context of the sed process.\n\n\nThis issue was fixed in version 4.10.","status":"published","published":"2026-04-20T11:59:32Z","modified":"2026-05-13T05:17:46Z","cvss":[{"version":"4.0","score":2.1,"vector":"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","level":"low"}],"updated_at":"2026-11-02T19:04:34.771814Z"}],"ghsa":[{"id":"GHSA-9r7w-j29g-xqx8","title":"When sed is invoked with both -i (in-place edit) and --follow-symlinks, the function...","description":"When sed is invoked with both -i (in-place edit) and --follow-symlinks, the function open_next_file() performs two separate, non-atomic filesystem operations on the same path: \n1. resolves symlink to its target and stores the resolved path for determining when output is written,\n2. opens the original symlink path (not the resolved one) to read the file. \nBetween these two calls there is a race window. If an attacker atomically replaces the symlink with a different target during that window, sed will: read content from the new (attacker-chosen) symlink target and write the processed result to the path recorded in step 1. This can lead to arbitrary file overwrite with attacker-controlled content in the context of the sed process.\n\n\nThis issue was fixed in version 4.10.","status":"published","published":"2026-04-20T12:32:01Z","modified":"2026-05-19T15:31:20Z","cvss":[{"version":"4.0","score":2.1,"vector":"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","level":"low"}],"cwes":["CWE-367"],"updated_at":"2026-11-02T15:08:12.004262Z"}],"nvd":[{"id":"CVE-2026-5958","description":"When sed is invoked with both -i (in-place edit) and --follow-symlinks, the function open_next_file() performs two separate, non-atomic filesystem operations on the same path: \n1. resolves symlink to its target and stores the resolved path for determining when output is written,\n2. opens the original symlink path (not the resolved one) to read the file. \nBetween these two calls there is a race window. If an attacker atomically replaces the symlink with a different target during that window, sed will: read content from the new (attacker-chosen) symlink target and write the processed result to the path recorded in step 1. This can lead to arbitrary file overwrite with attacker-controlled content in the context of the sed process.\n\n\nThis issue was fixed in version 4.10.","status":"published","published":"2026-04-20T12:16:08.433Z","modified":"2026-10-26T21:10:00.17Z","cvss":[{"version":"4.0","score":2.1,"vector":"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","level":"low","assessor":"secondary"}],"cwes":["CWE-367"],"updated_at":"2026-11-02T14:12:15.120927Z"}],"osv":[{"id":"DEBIAN-CVE-2026-5958","description":"When sed is invoked with both -i (in-place edit) and --follow-symlinks, the function open_next_file() performs two separate, non-atomic filesystem operations on the same path:  1. resolves symlink to its target and stores the resolved path for determining when output is written, 2. opens the original symlink path (not the resolved one) to read the file.  Between these two calls there is a race window. If an attacker atomically replaces the symlink with a different target during that window, sed will: read content from the new (attacker-chosen) symlink target and write the processed result to the path recorded in step 1. This can lead to arbitrary file overwrite with attacker-controlled content in the context of the sed process.   This issue was fixed in version 4.10.","status":"published","published":"2026-04-20T12:16:08.433Z","modified":"2026-10-27T09:47:43.368051107Z","cvss":[{"version":"4.0","score":2.1,"vector":"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","level":"low"}],"updated_at":"2026-11-02T15:45:57.932517Z"},{"id":"JLSEC-2026-213","title":"When sed is invoked with both -i (in-place edit) and --follow-symlinks, the function...","description":"When sed is invoked with both -i (in-place edit) and --follow-symlinks, the function `open_next_file()` performs two separate, non-atomic filesystem operations on the same path:\n\n 1. resolves symlink to its target and stores the resolved path for determining when output is written,\n 2. opens the original symlink path (not the resolved one) to read the file.\n    Between these two calls there is a race window. If an attacker atomically replaces the symlink with a different target during that window, sed will: read content from the new (attacker-chosen) symlink target and write the processed result to the path recorded in step 1. This can lead to arbitrary file overwrite with attacker-controlled content in the context of the sed process.\n\nThis issue was fixed in version 4.10.","status":"published","published":"2026-04-27T17:38:11.232Z","modified":"2026-07-25T18:23:48.757089706Z","cvss":[{"version":"4.0","score":2.1,"vector":"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","level":"low"}],"updated_at":"2026-11-02T15:47:18.573531Z"},{"id":"OESA-2026-2281","title":"sed security update","description":"Sed is a non-interactive command-line text editor. A stream editor is used to per-form basic text transformations on an input stream (a file or input from a pipeline).\r\n\r\nSecurity Fix(es):\n\nWhen sed is invoked with both -i (in-place edit) and --follow-symlinks, the function open_next_file() performs two separate, non-atomic filesystem operations on the same path: \n1. resolves symlink to its target and stores the resolved path for determining when output is written,\n2. opens the original symlink path (not the resolved one) to read the file. \nBetween these two calls there is a race window. If an attacker atomically replaces the symlink with a different target during that window, sed will: read content from the new (attacker-chosen) symlink target and write the processed result to the path recorded in step 1. This can lead to arbitrary file overwrite with attacker-controlled content in the context of the sed process.\n\n\nThis issue was fixed in version 4.10.(CVE-2026-5958)","status":"published","published":"2026-05-09T11:11:15Z","modified":"2026-08-18T01:19:52.920879557Z","cvss":[{"version":"4.0","score":2.1,"vector":"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","level":"low"}],"updated_at":"2026-11-02T15:52:46.087701Z"},{"id":"OESA-2026-2282","title":"sed security update","description":"Sed is a non-interactive command-line text editor. A stream editor is used to per-form basic text transformations on an input stream (a file or input from a pipeline).\r\n\r\nSecurity Fix(es):\n\nWhen sed is invoked with both -i (in-place edit) and --follow-symlinks, the function open_next_file() performs two separate, non-atomic filesystem operations on the same path: \n1. resolves symlink to its target and stores the resolved path for determining when output is written,\n2. opens the original symlink path (not the resolved one) to read the file. \nBetween these two calls there is a race window. If an attacker atomically replaces the symlink with a different target during that window, sed will: read content from the new (attacker-chosen) symlink target and write the processed result to the path recorded in step 1. This can lead to arbitrary file overwrite with attacker-controlled content in the context of the sed process.\n\n\nThis issue was fixed in version 4.10.(CVE-2026-5958)","status":"published","published":"2026-05-09T11:11:15Z","modified":"2026-08-18T01:19:52.873677246Z","cvss":[{"version":"4.0","score":2.1,"vector":"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","level":"low"}],"updated_at":"2026-11-02T15:52:46.087701Z"},{"id":"OESA-2026-2283","title":"sed security update","description":"Sed is a non-interactive command-line text editor. A stream editor is used to per-form basic text transformations on an input stream (a file or input from a pipeline).\r\n\r\nSecurity Fix(es):\n\nWhen sed is invoked with both -i (in-place edit) and --follow-symlinks, the function open_next_file() performs two separate, non-atomic filesystem operations on the same path: \n1. resolves symlink to its target and stores the resolved path for determining when output is written,\n2. opens the original symlink path (not the resolved one) to read the file. \nBetween these two calls there is a race window. If an attacker atomically replaces the symlink with a different target during that window, sed will: read content from the new (attacker-chosen) symlink target and write the processed result to the path recorded in step 1. This can lead to arbitrary file overwrite with attacker-controlled content in the context of the sed process.\n\n\nThis issue was fixed in version 4.10.(CVE-2026-5958)","status":"published","published":"2026-05-09T11:11:15Z","modified":"2026-08-18T01:19:53.081671483Z","cvss":[{"version":"4.0","score":2.1,"vector":"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","level":"low"}],"updated_at":"2026-11-02T15:52:46.087701Z"},{"id":"OESA-2026-2284","title":"sed security update","description":"Sed is a non-interactive command-line text editor. A stream editor is used to per-form basic text transformations on an input stream (a file or input from a pipeline).\r\n\r\nSecurity Fix(es):\n\nWhen sed is invoked with both -i (in-place edit) and --follow-symlinks, the function open_next_file() performs two separate, non-atomic filesystem operations on the same path: \n1. resolves symlink to its target and stores the resolved path for determining when output is written,\n2. opens the original symlink path (not the resolved one) to read the file. \nBetween these two calls there is a race window. If an attacker atomically replaces the symlink with a different target during that window, sed will: read content from the new (attacker-chosen) symlink target and write the processed result to the path recorded in step 1. This can lead to arbitrary file overwrite with attacker-controlled content in the context of the sed process.\n\n\nThis issue was fixed in version 4.10.(CVE-2026-5958)","status":"published","published":"2026-05-09T11:11:15Z","modified":"2026-08-18T01:19:53.373942948Z","cvss":[{"version":"4.0","score":2.1,"vector":"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","level":"low"}],"updated_at":"2026-11-02T15:52:46.087701Z"},{"id":"OESA-2026-2478","title":"sed security update","description":"Sed is a non-interactive command-line text editor. A stream editor is used to per-form basic text transformations on an input stream (a file or input from a pipeline).\r\n\r\nSecurity Fix(es):\n\nWhen sed is invoked with both -i (in-place edit) and --follow-symlinks, the function open_next_file() performs two separate, non-atomic filesystem operations on the same path: 1. resolves symlink to its target and stores the resolved path for determining when output is written, 2. opens the original symlink path (not the resolved one) to read the file. Between these two calls there is a race window. If an attacker atomically replaces the symlink with a different target during that window, sed will: read content from the new (attacker-chosen) symlink target and write the processed result to the path recorded in step 1. This can lead to arbitrary file overwrite with attacker-controlled content in the context of the sed process. This issue was fixed in version 4.10.(CVE-2026-5958)","status":"published","published":"2026-05-29T11:11:26Z","modified":"2026-08-18T01:20:00.808603085Z","cvss":[{"version":"4.0","score":2.1,"vector":"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","level":"low"}],"updated_at":"2026-11-02T15:52:46.449097Z"},{"id":"RHSA-2026:10995","title":"Red Hat Security Advisory: Red Hat Hardened Images RPMs bug fix and enhancement update","status":"published","published":"2026-05-29T10:07:28Z","modified":"2026-09-06T10:07:30Z","cvss":[{"version":"3.1","score":6.3,"vector":"CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:N/I:H/A:H","level":"medium"}],"updated_at":"2026-11-02T15:53:18.066978Z"},{"id":"UBUNTU-CVE-2026-5958","description":"When sed is invoked with both -i (in-place edit) and --follow-symlinks, the function open_next_file() performs two separate, non-atomic filesystem operations on the same path: 1. resolves symlink to its target and stores the resolved path for determining when output is written, 2. opens the original symlink path (not the resolved one) to read the file. Between these two calls there is a race window. If an attacker atomically replaces the symlink with a different target during that window, sed will: read content from the new (attacker-chosen) symlink target and write the processed result to the path recorded in step 1. This can lead to arbitrary file overwrite with attacker-controlled content in the context of the sed process. This issue was fixed in version 4.10.","status":"published","published":"2026-04-19T00:00:00Z","modified":"2026-05-29T10:59:18.893969563Z","cvss":[{"version":"4.0","score":2.1,"vector":"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","level":"low"}],"updated_at":"2026-11-02T16:56:41.911783Z"},{"id":"AZL-83102","title":"CVE-2026-5958 affecting package sed for versions less than 4.9-2","description":"When sed is invoked with both -i (in-place edit) and --follow-symlinks, the function open_next_file() performs two separate, non-atomic filesystem operations on the same path: \n1. resolves symlink to its target and stores the resolved path for determining when output is written,\n2. opens the original symlink path (not the resolved one) to read the file. \nBetween these two calls there is a race window. If an attacker atomically replaces the symlink with a different target during that window, sed will: read content from the new (attacker-chosen) symlink target and write the processed result to the path recorded in step 1. This can lead to arbitrary file overwrite with attacker-controlled content in the context of the sed process.\n\n\nThis issue was fixed in version 4.10.","status":"published","published":"2026-04-20T12:16:08Z","modified":"2026-11-05T05:40:51Z","updated_at":"2026-11-05T16:41:24.988217Z"},{"id":"MGASA-2026-0128","title":"Updated sed packages fix security vulnerability","description":"Race Condition in GNU Sed. (CVE-2026-5958)\n","status":"published","published":"2026-05-13T07:00:52Z","modified":"2026-05-13T07:18:31.098895Z","updated_at":"2026-11-02T15:49:43.178336Z"},{"id":"openSUSE-SU-2026:10649-1","title":"sed-4.10-1.1 on GA media","description":"These are all security issues fixed in the sed-4.10-1.1 package on the GA media of openSUSE Tumbleweed.","status":"published","published":"2026-04-28T00:00:00Z","modified":"2026-04-29T08:02:25.328263Z","updated_at":"2026-11-02T16:58:38.415593Z"},{"id":"openSUSE-SU-2026:21024-1","title":"Security update for sed","description":"This update for sed fixes the following issue\n\n- CVE-2026-5958: a TOCTOU race can allow to read attacker-controlled content and write it to an unintended file\n  (bsc#1262144).\n","status":"published","published":"2026-06-22T14:30:37Z","modified":"2026-06-30T18:24:37.09178723Z","updated_at":"2026-11-02T16:58:41.885092Z"},{"id":"SUSE-SU-2026:1659-1","title":"Security update for sed","description":"This update for sed fixes the following issues:\n\n- CVE-2026-5958: TOCTOU race allows write of user-controlled content to unintended files and can lead to arbitrary file\n  overwrite (bsc#1262144).\n","status":"published","published":"2026-04-29T11:09:09Z","modified":"2026-04-30T08:16:27.1555Z","updated_at":"2026-11-02T15:54:01.610851Z"},{"id":"SUSE-SU-2026:1699-1","title":"Security update for sed","description":"This update for sed fixes the following issue:\n\n- CVE-2026-5958: a TOCTOU race can allow to read attacker-controlled content and write it to an unintended file (bsc#1262144).\n","status":"published","published":"2026-05-06T07:26:44Z","modified":"2026-05-07T08:45:30.306616Z","updated_at":"2026-11-02T15:54:01.610851Z"},{"id":"SUSE-SU-2026:1941-1","title":"Security update for sed","description":"This update for sed fixes the following issue:\n\n- CVE-2026-5958: a TOCTOU race can allow to read attacker-controlled content and write it to an unintended file (bsc#1262144).\n","status":"published","published":"2026-05-18T07:44:38Z","modified":"2026-05-19T08:45:08.223441361Z","updated_at":"2026-11-02T15:54:01.610851Z"},{"id":"SUSE-SU-2026:21413-1","title":"Security update for sed","description":"This update for sed fixes the following issue:\n\n- CVE-2026-5958: TOCTOU race allows write of user-controlled content to unintended files and can lead to arbitrary file\n  overwrite (bsc#1262144).\n","status":"published","published":"2026-04-27T17:25:16Z","modified":"2026-05-01T18:26:49.283188Z","updated_at":"2026-11-02T15:54:02.312556Z"},{"id":"SUSE-SU-2026:21448-1","title":"Security update for sed","description":"This update for sed fixes the following issue:\n\n- CVE-2026-5958: TOCTOU race allows write of user-controlled content to unintended files and can lead to arbitrary file\n  overwrite (bsc#1262144).\n","status":"published","published":"2026-04-27T17:15:37Z","modified":"2026-05-05T18:23:55.62326Z","updated_at":"2026-11-02T15:54:02.312556Z"},{"id":"SUSE-SU-2026:22256-1","title":"Security update for sed","description":"This update for sed fixes the following issue\n\n- CVE-2026-5958: a TOCTOU race can allow to read attacker-controlled content and write it to an unintended file\n  (bsc#1262144).\n","status":"published","published":"2026-06-22T14:28:56Z","modified":"2026-06-30T18:24:26.452059683Z","updated_at":"2026-11-02T15:54:02.654057Z"},{"id":"SUSE-SU-2026:22325-1","title":"Security update for sed","description":"This update for sed fixes the following issue\n\n- CVE-2026-5958: a TOCTOU race can allow to read attacker-controlled content and write it to an unintended file\n  (bsc#1262144).\n","status":"published","published":"2026-06-22T14:28:56Z","modified":"2026-07-02T18:24:10.966684892Z","updated_at":"2026-11-02T15:54:03.080707Z"},{"id":"USN-8229-1","title":"sed vulnerability","description":"Michał Majchrowicz and Marcin Wyczechowski discovered that sed incorrectly\nhandled symbolic links when performing in-place edits. A local attacker\ncould possibly use this issue to overwrite arbitrary files.","status":"published","published":"2026-05-04T12:24:18Z","modified":"2026-05-20T16:04:03.111048743Z","updated_at":"2026-11-02T16:58:22.951676Z"},{"id":"USN-8229-2","title":"sed vulnerability","description":"USN-8229-1 fixed a vulnerability in sed. This update provides the\ncorresponding update for Ubuntu 18.04 LTS and Ubuntu 20.04 LTS.\n\nOriginal advisory details:\n\n Michał Majchrowicz and Marcin Wyczechowski discovered that sed\n incorrectly handled symbolic links when performing in-place edits.\n A local attacker could possibly use this issue to overwrite\n arbitrary files.","status":"published","published":"2026-05-28T18:34:13Z","modified":"2026-05-29T10:59:19.228985104Z","updated_at":"2026-11-02T16:58:22.951676Z"}]}}
