CVE-2024-39331: In Emacs before 29.4, org-link-expand-abbrev in lisp/ol.el expands a %(...) link abbrev even when it specifies
CVE-2024-39331 is a critical-severity flaw (CVSS 9.8) affecting emacs. Below: why it ranks where it does, which versions are affected, what to do, and the exact commands.
In Emacs before 29.4, org-link-expand-abbrev in lisp/ol.el expands a %(...) link abbrev even when it specifies an unsafe function, such as shell-command-to-string. This affects Org Mode before 9.7.5.
Why this priority
- Critical severity
- Remotely exploitable, no login, no user action
A fixed release or distro patch exists.
Risk facts
| CVSS score | 9.8 (Critical) |
| Attack vector | Network (remote) |
| Attack complexity | Low |
| Privileges needed | None |
| User interaction | None |
| EPSS exploit chance | 1.3% (top 29%) |
| CISA exploited list | No |
| Weakness | CWE-94 |
| Published | 2024-06-23 |
| Last modified | 2026-06-17 |
Last updated 2026-06-17 · Sources: CVE Program, NVD, CISA KEV, EPSS and vendor advisories · How we score
Am I affected?
Timeline
- Published CVE record published
- Updated Record last modified
Scores and fixes here are computed automatically from those and other public sources. Confirm with the vendor advisory before changing production systems.
Quick answers
How do I fix CVE-2024-39331?
emacs: upgrade to 29.4. Exact commands for each OS are on this page.
Is CVE-2024-39331 being exploited?
CVE-2024-39331 is not on the CISA Known Exploited Vulnerabilities list at the time of the last update. Check again, as this can change.
What does CVE-2024-39331 affect?
CVE-2024-39331 affects emacs. Severity is critical (CVSS 9.8). In Emacs before 29.4, org-link-expand-abbrev in lisp/ol.el expands a %(...) link abbrev even when it specifies an unsafe function, such as shell-command-to-string. This affects Org Mode before 9.7.5.
How urgent is CVE-2024-39331?
Priority 57/100. Critical severity; Remotely exploitable, no login, no user action
Related CVEs
- CVE-2026-6861 MEDIUM 6.1 UPGRADE A flaw was found in GNU Emacs
- CVE-2024-53920 HIGH 7.8 UPGRADE In elisp-mode.el in GNU Emacs before 30.1, a user who chooses to invoke elisp-completion-at-point (for code co
- CVE-2024-30205 HIGH 7.1 UPGRADE UPGRADE In Emacs before 29.3, Org mode considers contents of remote files to be trusted
- CVE-2024-30204 LOW 2.8 UPGRADE UPGRADE In Emacs before 29.3, LaTeX preview is enabled by default for e-mail attachments.
- CVE-2024-30203 MEDIUM 5.5 UPGRADE UPGRADE In Emacs before 29.3, Gnus treats inline MIME contents as trusted.