// For flags

CVE-2021-45444

zsh: Prompt expansion vulnerability

Severity Score

7.8
*CVSS v3.1

Exploit Likelihood

*EPSS

Affected Versions

*CPE

Public Exploits

0
*Multiple Sources

Exploited in Wild

-
*KEV

Decision

-
*SSVC
Descriptions

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 expansion.

En zsh versiones anteriores a 5.8.1, un atacante puede lograr una ejecución de código si controla la salida de un comando dentro del prompt, como lo demuestra un argumento %F. Esto ocurre debido a la expansión recursiva PROMPT_SUBST

A vulnerability was found in zsh in the parsecolorchar() function of prompt.c file. This flaw allows an attacker to perform code execution if they control a command output inside the prompt, as stated by a %F%K argument. This occurs because of recursive PROMPT_SUBST expansion.

*Credits: N/A
CVSS Scores
Attack Vector
Local
Attack Complexity
Low
Privileges Required
None
User Interaction
Required
Scope
Unchanged
Confidentiality
High
Integrity
High
Availability
High
Attack Vector
Network
Attack Complexity
High
Authentication
None
Confidentiality
Partial
Integrity
Partial
Availability
Partial
* Common Vulnerability Scoring System
SSVC
  • Decision:-
Exploitation
-
Automatable
-
Tech. Impact
-
* Organization's Worst-case Scenario
Timeline
  • 2021-12-21 CVE Reserved
  • 2022-02-13 CVE Published
  • 2024-08-04 CVE Updated
  • 2024-10-29 EPSS Updated
  • ---------- Exploited in Wild
  • ---------- KEV Due Date
  • ---------- First Exploit
CWE
  • CWE-77: Improper Neutralization of Special Elements used in a Command ('Command Injection')
CAPEC
Affected Vendors, Products, and Versions
Vendor Product Version Other Status
Vendor Product Version Other Status <-- --> Vendor Product Version Other Status
Zsh
Search vendor "Zsh"
Zsh
Search vendor "Zsh" for product "Zsh"
< 5.8.1
Search vendor "Zsh" for product "Zsh" and version " < 5.8.1"
-
Affected
Fedoraproject
Search vendor "Fedoraproject"
Fedora
Search vendor "Fedoraproject" for product "Fedora"
34
Search vendor "Fedoraproject" for product "Fedora" and version "34"
-
Affected
Fedoraproject
Search vendor "Fedoraproject"
Fedora
Search vendor "Fedoraproject" for product "Fedora"
35
Search vendor "Fedoraproject" for product "Fedora" and version "35"
-
Affected
Debian
Search vendor "Debian"
Debian Linux
Search vendor "Debian" for product "Debian Linux"
9.0
Search vendor "Debian" for product "Debian Linux" and version "9.0"
-
Affected
Debian
Search vendor "Debian"
Debian Linux
Search vendor "Debian" for product "Debian Linux"
10.0
Search vendor "Debian" for product "Debian Linux" and version "10.0"
-
Affected
Debian
Search vendor "Debian"
Debian Linux
Search vendor "Debian" for product "Debian Linux"
11.0
Search vendor "Debian" for product "Debian Linux" and version "11.0"
-
Affected
Apple
Search vendor "Apple"
Mac Os X
Search vendor "Apple" for product "Mac Os X"
>= 10.15 < 10.15.7
Search vendor "Apple" for product "Mac Os X" and version " >= 10.15 < 10.15.7"
-
Affected
Apple
Search vendor "Apple"
Mac Os X
Search vendor "Apple" for product "Mac Os X"
10.15.7
Search vendor "Apple" for product "Mac Os X" and version "10.15.7"
security_update_2020
Affected
Apple
Search vendor "Apple"
Mac Os X
Search vendor "Apple" for product "Mac Os X"
10.15.7
Search vendor "Apple" for product "Mac Os X" and version "10.15.7"
security_update_2020-001
Affected
Apple
Search vendor "Apple"
Mac Os X
Search vendor "Apple" for product "Mac Os X"
10.15.7
Search vendor "Apple" for product "Mac Os X" and version "10.15.7"
security_update_2020-005
Affected
Apple
Search vendor "Apple"
Mac Os X
Search vendor "Apple" for product "Mac Os X"
10.15.7
Search vendor "Apple" for product "Mac Os X" and version "10.15.7"
security_update_2020-007
Affected
Apple
Search vendor "Apple"
Mac Os X
Search vendor "Apple" for product "Mac Os X"
10.15.7
Search vendor "Apple" for product "Mac Os X" and version "10.15.7"
security_update_2021-001
Affected
Apple
Search vendor "Apple"
Mac Os X
Search vendor "Apple" for product "Mac Os X"
10.15.7
Search vendor "Apple" for product "Mac Os X" and version "10.15.7"
security_update_2021-002
Affected
Apple
Search vendor "Apple"
Mac Os X
Search vendor "Apple" for product "Mac Os X"
10.15.7
Search vendor "Apple" for product "Mac Os X" and version "10.15.7"
security_update_2021-003
Affected
Apple
Search vendor "Apple"
Mac Os X
Search vendor "Apple" for product "Mac Os X"
10.15.7
Search vendor "Apple" for product "Mac Os X" and version "10.15.7"
security_update_2021-006
Affected
Apple
Search vendor "Apple"
Mac Os X
Search vendor "Apple" for product "Mac Os X"
10.15.7
Search vendor "Apple" for product "Mac Os X" and version "10.15.7"
security_update_2021-007
Affected
Apple
Search vendor "Apple"
Mac Os X
Search vendor "Apple" for product "Mac Os X"
10.15.7
Search vendor "Apple" for product "Mac Os X" and version "10.15.7"
security_update_2021-008
Affected
Apple
Search vendor "Apple"
Mac Os X
Search vendor "Apple" for product "Mac Os X"
10.15.7
Search vendor "Apple" for product "Mac Os X" and version "10.15.7"
security_update_2022-001
Affected
Apple
Search vendor "Apple"
Mac Os X
Search vendor "Apple" for product "Mac Os X"
10.15.7
Search vendor "Apple" for product "Mac Os X" and version "10.15.7"
security_update_2022-002
Affected
Apple
Search vendor "Apple"
Mac Os X
Search vendor "Apple" for product "Mac Os X"
10.15.7
Search vendor "Apple" for product "Mac Os X" and version "10.15.7"
security_update_2022-003
Affected
Apple
Search vendor "Apple"
Macos
Search vendor "Apple" for product "Macos"
>= 11.0 < 11.6.6
Search vendor "Apple" for product "Macos" and version " >= 11.0 < 11.6.6"
-
Affected
Apple
Search vendor "Apple"
Macos
Search vendor "Apple" for product "Macos"
>= 12.0.0 < 12.4
Search vendor "Apple" for product "Macos" and version " >= 12.0.0 < 12.4"
-
Affected