CVE-2022-45939
NixOS vulnerability analysis and mitigation

Overview

CVE-2022-45939 affects GNU Emacs through version 28.2, where attackers could execute arbitrary commands via shell metacharacters in the name of a source-code file. The vulnerability exists because lib-src/etags.c uses the system C library function in its implementation of the ctags program (CVE).

Technical details

The vulnerability stems from the improper handling of shell metacharacters in the ctags functionality of Emacs. The issue specifically resides in lib-src/etags.c, which uses the system C library function when calling the external ctags binary. A victim may use the "ctags *" command (suggested in the ctags documentation) in a situation where the current working directory has contents that depend on untrusted input (Debian LTS).

Impact

This vulnerability allows attackers to execute arbitrary commands through shell metacharacters in source-code filenames when using the ctags functionality (Debian Security).

Mitigation and workarounds

Multiple vendors have released patches to address this vulnerability. Debian has fixed the issue in version 1:26.1+1-3.2+deb10u3 for Debian 10 and version 1:27.1+1-3.1+deb11u1 for Debian 11. Fedora has addressed the vulnerability in emacs-28.2-1.fc36 and emacs-28.2-1.fc37 (Debian LTS, Fedora).

Additional resources


SourceThis report was generated using AI

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

“Best User Experience I have ever seen, provides full visibility to cloud workloads.”
David EstlickCISO
“Wiz provides a single pane of glass to see what is going on in our cloud environments.”
Adam FletcherChief Security Officer
“We know that if Wiz identifies something as critical, it actually is.”
Greg PoniatowskiHead of Threat and Vulnerability Management