CVE-2024-5742Nano: running `chmod` and `chown` on the filename allows malicious user to replace the emergency file with a malicious symlink to a root-owned file
Updated under an hour ago ()
Does this affect you?
It affects Red Hat Enterprise Linux 8 and 4 other products. Add what you run to find out whether that includes you.
No exploitation reported and no EPSS estimate yet.
Do this next
Free account, 1 product
A vulnerability was found in GNU Nano that allows a possible privilege escalation through an insecure temporary file. If Nano is killed while editing, a file it saves to an emergency file with the permissions of the running user provides a window of opportunity for attackers to escalate privileges through a malicious symlink.
- CVSS
- 6.7 MEDIUM (v3.1, CNA)CVSS:3.1/AV:L/AC:H/PR:L/UI:R/S:U/C:H/I:H/A:H
- Weakness (CWE)
- CWE-59
- Known exploited
- Not in CISA's KEV catalog
- EPSS (exploitation in the next 30 days)
- Not loaded for this CVE
- Assigned by
- redhat
- NVD analysis
- Modified
- Record last updated
- Oct 15, 2026
- First seen by InfoSec Signals
- Oct 15, 2026
Affected products
Red Hat Red Hat Enterprise Linux 8 redhat:enterprise_linux | from 0:2.9.8-3.el8_10 not affected | CNA record |
Siemens SIMATIC S7-1500 CPU 1518-4 PN/DP MFP siemens:simatic_s7_1500_cpu_1518_4_pn_dp_mfp (from the name) | from V3.1.0 before V3.1.5 | CISA ADP |
Siemens SIMATIC S7-1500 CPU 1518F-4 PN/DP MFP siemens:simatic_s7_1500_cpu_1518f_4_pn_dp_mfp (from the name) | from V3.1.0 before V3.1.5 | CISA ADP |
Siemens SIPLUS S7-1500 CPU 1518-4 PN/DP MFP siemens:siplus_s7_1500_cpu_1518_4_pn_dp_mfp (from the name) | from V3.1.0 before V3.1.5 | CISA ADP |
gnu nano gnu:nano | from 2.2.0 before 8.0 | NVD |
redhat enterprise_linux redhat:enterprise_linux | 6.0; 7.0; 8.0; 9.0 | NVD |
References
- https://access.redhat.com/errata/RHSA-2024:6986vendor-advisory, x-refsource-redhat
- https://access.redhat.com/errata/RHSA-2024:9430vendor-advisory, x-refsource-redhat
- https://access.redhat.com/security/cve/CVE-2024-5742vdb-entry, x-refsource-redhat, vendor-advisory
- https://bugzilla.redhat.com/show_bug.cgi?id=2278574issue-tracking, x-refsource-redhat, vendor-advisory
- https://lists.debian.org/debian-lts-announce/2024/06/msg00006.html
- https://cert-portal.siemens.com/productcert/html/ssa-398330.html
The CVE record on cve.org NVD's entry
The CVE record is authoritative. Products marked “from the name” were identified from the CNA's free-text names, not a CPE, and are matched less certainly. This product uses the NVD API but is not endorsed or certified by the NVD.