CVE-2021-45444
In zsh before 5.8.1, an attacker can achieve code execution if they control a command output inside the prompt, as demonstrated by a %F argument. This occurs because of recursive PROMPT_SUBST
02 Description
In zsh before 5.8.1, an attacker can achieve code execution if they control a command output inside the prompt, as demonstrated by a %F argument. This occurs because of recursive PROMPT_SUBST
03 Exploitation and scoring
- Exploitation
- Not assessed. CISA has not published an exploitation assessment for this record, and it is not in the KEV catalog. That is an absence of assessment, not a finding of no risk.
- SSVC decision
- Not assessed by CISA
- EPSS probability
- 1.98% probability of exploitation activity in the next 30 days.
- EPSS percentile
- Equal to or higher than the score of 80.3% of scored records. A rank, not a probability.
- NVD base score
- 7.8 (CVSS v3.x), scored by the NVD independently of the CNA.
- NVD CVSS vector
- CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
- NVD analysis status
- Modified. NVD last modified this record on 2026-06-17.
- Red Hat severity
- Moderate. Red Hat's rating for its own products, not a CVSS rating.
Exploit-prediction scores from FIRST. Independent scoring and analysis status from the NVD. Vendor severity from Red Hat. Exploitation assessment and catalog membership from CISA.
04 Metadata
- Published
- 2022-02-13 05:32Z4 YR AGO
- Last updated
- 2024-08-04 04:39Z2 YR AGO
- Reserved
- 2021-12-21
- Assigning CNA
- mitre
- Record state
- PUBLISHED
- Severity
- Not rated by the issuing CNA
- CNA CVSS vector
- Not published by the issuing CNA
- Weaknesses
- CWE-77Improper Neutralization of Special Elements used in a Command ('Command Injection')Class
- Data version
- 5.1
- Document digest
- 55e333e1c2b9e1d299009045f982ec58b4fd7da89c8e4fc04af643463244eb98
05 Affected products
06 References
- zsh.sourceforge.iohttps://zsh.sourceforge.io/releases.html
- vuln.ryotak.mehttps://vuln.ryotak.me/advisories/63
- lists.fedoraproject.orgFEDORA-2022-adf0c6d196https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/2P3LPMGENEHKDWFO4MWMZSZL6G7Y4CV7/
- www.debian.orgDSA-5078https://www.debian.org/security/2022/dsa-5078
- lists.debian.org[debian-lts-announce] 20220218 [SECURITY] [DLA 2926-1] zsh security updatehttps://lists.debian.org/debian-lts-announce/2022/02/msg00020.html
- lists.fedoraproject.orgFEDORA-2022-0a06987c3chttps://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/BWF3EXNBX5SVFDBL4ZFOD4GJBWFUKWN4/
- support.apple.comhttps://support.apple.com/kb/HT213257
- support.apple.comhttps://support.apple.com/kb/HT213256
- support.apple.comhttps://support.apple.com/kb/HT213255
- seclists.org20220516 APPLE-SA-2022-05-16-4 Security Update 2022-004 Catalinahttp://seclists.org/fulldisclosure/2022/May/33
- seclists.org20220516 APPLE-SA-2022-05-16-3 macOS Big Sur 11.6.6http://seclists.org/fulldisclosure/2022/May/35
- seclists.org20220516 APPLE-SA-2022-05-16-2 macOS Monterey 12.4http://seclists.org/fulldisclosure/2022/May/38
07 Fixed in
AlmaLinux 8
- zsh Fixed in 5.5.1-9.el8
- zsh-html Fixed in 5.5.1-9.el8
Source: AlmaLinux, AlmaLinux OS. Copyright (c) 2023 AlmaLinux OS. Licensed under MIT License. Received through OSV.dev. Reformatted by exploit.cc.
CloudLinux 8
- zsh Fixed in 5.5.1-9.el8
- zsh-html Fixed in 5.5.1-9.el8
Derived from AlmaLinux 8. Partial coverage: only packages taken from AlmaLinux 8 are listed.
Source: CloudLinux errata, CloudLinux Inc. Derived from: AlmaLinux, AlmaLinux OS. Copyright (c) 2023 AlmaLinux OS. Licensed under MIT License. Received through OSV.dev. Reformatted by exploit.cc.
Debian 12
- zsh Fixed in 5.8.1-1
Source: Debian Security Tracker, the Debian security team. Received through OSV.dev. Reformatted by exploit.cc.
Debian 13
- zsh Fixed in 5.8.1-1
Source: Debian Security Tracker, the Debian security team. Received through OSV.dev. Reformatted by exploit.cc.
Debian 14
- zsh Fixed in 5.8.1-1
Source: Debian Security Tracker, the Debian security team. Received through OSV.dev. Reformatted by exploit.cc.
Ubuntu 18.04 LTS
- zsh Fixed in 5.4.2-3ubuntu3.2
Source: Ubuntu, Canonical Ltd. Licensed under CC BY-SA 4.0. Received through OSV.dev. Reformatted by exploit.cc.
Ubuntu 20.04 LTS
- zsh Fixed in 5.8-3ubuntu1.1
Source: Ubuntu, Canonical Ltd. Licensed under CC BY-SA 4.0. Received through OSV.dev. Reformatted by exploit.cc.
Ubuntu 22.04 LTS
- zsh No fix yet
Source: Ubuntu, Canonical Ltd. Licensed under CC BY-SA 4.0. Received through OSV.dev. Reformatted by exploit.cc.
Ubuntu Pro 16.04 LTS
- zsh Fixed in 5.1.1-1ubuntu2.3+esm1Available with Ubuntu Pro (Infra-only): https://ubuntu.com/pro
Source: Ubuntu, Canonical Ltd. Licensed under CC BY-SA 4.0. Received through OSV.dev. Reformatted by exploit.cc.
A release or ecosystem missing from this list has no record here. It may be unaffected or not covered by the source. Source notices and licences.