CVE-2022-48338 json
An issue was discovered in GNU Emacs through 28.2.
published 2023-02-20 3 y ago modified 2026-06-17 4 mo ago also EUVD-2022-51038
- cvss
- 7.3
- version 3.1, CNA
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 1.6%
- EPSS 1.6% chance of exploitation in 30 days, percentile 76%
- public exploits
- 0
- none known
Summary
An issue was discovered in GNU Emacs through 28.2. In ruby-mode.el, the ruby-find-library-file function has a local command injection vulnerability. The ruby-find-library-file function is an interactive function, and bound to C-c C-f. Inside the function, the external command gem is called through shell-command-to-string, but the feature-name parameters are not escaped. Thus, malicious Ruby source files may cause commands to be executed.
Patch / fix
- emacs Debian 14, Debian 13, Debian 12 1:28.2+1-11
debian advisories DEBIAN-CVE-2022-48338
- emacs Ubuntu 22.04 LTS 1:27.1+1-3ubuntu5.2
ubuntu advisories UBUNTU-CVE-2022-48338
Ubuntu security data © Canonical Ltd., from https://github.com/canonical/ubuntu-security-notices via OSV; changed: normalised to fixed package versions per release. CC BY-SA 4.0
- emacs RHEL 9 1:27.2-8.el9_2.1
- emacs-nox RHEL 9 1:27.2-8.el9_2.1
- emacs-lucid RHEL 9 1:27.2-8.el9_2.1
- emacs-common RHEL 9 1:27.2-8.el9_2.1
- emacs-filesystem RHEL 9 1:27.2-8.el9_2.1
red hat advisories RHSA-2023:2626
- emacs SLE Module for Desktop Applications 15 SP4, SLE Module for Basesystem 15 SP4, openSUSE Leap 15.4 27.2-150400.3.6.1
suse advisories SUSE-SU-2023:0598-1
- emacs openSUSE Tumbleweed 28.2-2.1
opensuse advisories openSUSE-SU-2024:12721-1
- emacs AlmaLinux 9 1:27.2-8.el9_2.1
- emacs-nox AlmaLinux 9 1:27.2-8.el9_2.1
- emacs-lucid AlmaLinux 9 1:27.2-8.el9_2.1
- emacs-common AlmaLinux 9 1:27.2-8.el9_2.1
- emacs-filesystem AlmaLinux 9 1:27.2-8.el9_2.1
almalinux advisories ALSA-2023:2626
Vendor advisories
What the vendors themselves say about their products: affected, fixed or not affected, and what to do.
red hat product security vex CVE-2022-48338 updated cvss 7.3
emacs: local command injection in ruby-mode.el
-
Red Hat Enterprise Linux 6 emacs, emacs-el, emacs-nox, emacs-commonaffected: no fix planned “Out of support scope”
-
Red Hat Enterprise Linux 7 emacs, emacs-el, emacs-nox, emacs-common, emacs-terminal, emacs-filesystem Red Hat Enterprise Linux 8 emacs, emacs-nox, emacs-lucid, emacs-common, emacs-terminal, emacs-filesystemaffected: no fix available
-
Red Hat Enterprise Linux AppStream (v. 9) emacs 27.2-8.el9_2.1, emacs-nox 27.2-8.el9_2.1, emacs-lucid 27.2-8.el9_2.1, emacs-common 27.2-8.el9_2.1, emacs-filesystem 27.2-8.el9_2.1fixed: vendor fix RHSA-2023:2626
Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf
CISA SSVC
- Exploitation
- none
- Automatable
- no
- Technical impact
- total
- Assessed
- 19 mo ago
Exploit prediction
1.64% chance of exploitation in the next 30 days, higher than 76% of all scored CVEs (FIRST EPSS, 2026-11-08).
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| CISA ADP | 3.1 | 7.3 | CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H |
| NVD | 3.1 | 7.3 | CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H |
| CNA | 3.1 | 7.3 | CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:H |
Classification
- Weakness
-
- CWE-77 Improper Neutralization of Special Elements used in a Command
References
-
git.savannah.gnu.org
/cgit/emacs.git/commit/?id=9a3b08061feea14d6f37685ca1ab8801758bfd1c
patch
-
debian.org
/security/2023/dsa-5360
vendor-advisory, third-party-advisory
-
lists.fedoraproject.org
/archives/list/package-announce%40lists.fedoraproject.org/message/U6HDBUQNAH2WL4MHWCTUZLN7NGF7CHTK/
vendor-advisory
-
lists.fedoraproject.org
/archives/list/package-announce%40lists.fedoraproject.org/message/FLPQ4K6H2S5TY3L5UDN4K4B3L5RQJYQ6/
vendor-advisory
Sources
- CVE List CVE-2022-48338
- NVD CVE-2022-48338
Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.