CVE-2026-96442

Emacs: emacs: arbitrary code execution in flymake mode

Published Sep 23, 2026 CVSS 3.1 · 7.8 High EPSS < 1% KEV · Not listed
Description
A code execution flaw was found in Emacs, affecting versions prior to 31.2. The Flymake mode using language backends other than Lisp would execute arbitrary code from the edited file while performing syntax checking. Viewing or editing untrusted files using Emacs could lead to arbitrary code execution with the privileges of the user running Emacs.

Analysis

AI-generated

Technical impact

A flaw in the Emacs text editor allows the Fit‑make mode to execute code supplied by the edited file when the language backend is not Lisp. The execution occurs during syntax checking, giving the running user the ability to run arbitrary code from the file. This flaw maps to the input evaluation weakness CWE‑94 and can compromise confidentiality, integrity, and availability of the user’s environment.

Affected Systems

Red Hat Enterprise Linux 10, 6, 7, 8 and 9 users of Emacs versions before 31.2 are affected. The vulnerability manifests when the user opens or edits a file under Emacs that is processed by Flymake with a non‑Lisp backend.

Risk and Exploitability

The CVSS score of 7.8 indicates high severity. Exploitation requires that an attacker supply or influence a file that Emacs processes locally, so a privileged or local attacker can trigger the flaw by opening or editing a crafted file. EPSS data is absent, and the vulnerability is not listed in CISA KEV, but the high CVSS suggests the risk is significant for environments where untrusted files may be opened by privileged users.

Remediation

Vendor Workaround

To mitigate this issue, users should avoid opening or editing untrusted text files with Emacs. Exercise caution when handling files from unknown or suspicious sources, as interacting with them can lead to arbitrary code execution.


OpenCVE Recommended Actions

  • Upgrade Emacs to version 31.2 or later where the issue is fixed.
  • If an update cannot be applied immediately, disable Flymake for non‑Lisp backends or configure it to use safe, non‑executing syntax checkers.
  • Restrict file access and ensure that only trusted users can create or modify files that Emacs will open or syntax‑check.
  • Consider implementing SELinux or AppArmor confinement for the Emacs process to limit the impact of accidental code execution.

Generated by OpenCVE AI on September 23, 2026 at 14:17 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories available
History
Type Values Removed Values Added
CPEs cpe:/o:redhat:enterprise_linux:10.3
References
Type Values Removed Values Added
First Time appeared Redhat rhel Els
CPEs cpe:/o:redhat:enterprise_linux:6
cpe:/o:redhat:enterprise_linux:7
cpe:/o:redhat:rhel_els:6
cpe:/o:redhat:rhel_els:7
Vendors & Products Redhat rhel Els
Type Values Removed Values Added
CPEs cpe:/o:redhat:enterprise_linux:8 cpe:/a:redhat:enterprise_linux:8::appstream
cpe:/o:redhat:enterprise_linux:8::baseos
References
Type Values Removed Values Added
CPEs cpe:/o:redhat:enterprise_linux:9 cpe:/a:redhat:enterprise_linux:9::appstream
References
Type Values Removed Values Added
CPEs cpe:/o:redhat:enterprise_linux:10 cpe:/o:redhat:enterprise_linux:10.2
References
Type Values Removed Values Added
Title Emacs: emacs: arbitrary code execution, incomplete fix for cve-2024-53920 Emacs: emacs: arbitrary code execution in flymake mode
Type Values Removed Values Added
First Time appeared Gnu
Gnu emacs
Vendors & Products Gnu
Gnu emacs
Type Values Removed Values Added
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'total'}, 'version': '2.0.3'}

Type Values Removed Values Added
Description A code execution flaw was found in Emacs, affecting versions prior to 31.2. The Flymake mode using language backends other than Lisp would execute arbitrary code from the edited file while performing syntax checking. Viewing or editing untrusted files using Emacs could lead to arbitrary code execution with the privileges of the user running Emacs.
Title Emacs: emacs: arbitrary code execution, incomplete fix for cve-2024-53920
First Time appeared Redhat
Redhat enterprise Linux
Weaknesses CWE-94
CPEs cpe:/o:redhat:enterprise_linux:10
cpe:/o:redhat:enterprise_linux:6
cpe:/o:redhat:enterprise_linux:7
cpe:/o:redhat:enterprise_linux:8
cpe:/o:redhat:enterprise_linux:9
Vendors & Products Redhat
Redhat enterprise Linux
References
Metrics cvssV3_1

{'score': 7.8, 'vector': 'CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H'}

Weaknesses
  • CWE-94

    Improper Control of Generation of Code ('Code Injection')

Sources

Status
PUBLISHED
Assigner
redhat
Published
Updated
Nov 12, 2026, 5:26 AM
Reserved
Sep 23, 2026, 8:58 AM
Status
Awaiting Analysis
Published
Sep 23, 2026, 11:17 AM
Modified
Nov 12, 2026, 6:17 AM
Severity
Important
Public date
Sep 14, 2026, 12:00 AM