Read the docs
TI-2022-18703 Aliases CVE-2022-39327GHSA-47xc-9rr2-q7p4

Improper Control of Generation of Code ('Code Injection') in Azure CLI

Priority HIGH 76CWE-94Published · Updated

Key facts

Attack vector
Network
Privileges required
None
User interaction
None
Attack complexity
Low
Impact type
Code execution
Confidentiality · integrity · availability
High · High · High
Fix status
Fixed

Attack profile from CVSS 3.1 · NVD. Fix status from CNA and GitHub. Impact type from CWE-94.

Summary

Azure CLI is the command-line interface for Microsoft Azure. In versions previous to 2.40.0, Azure CLI contains a vulnerability for potential code injection. Critical scenarios are where a hosting machine runs an Azure CLI command where parameter values have been provided by an external source. The vulnerability is only applicable when the Azure CLI command is run on a Windows machine and with any version of PowerShell and when the parameter value contains the `&` or `|` symbols. If any of these prerequisites are not met, this vulnerability is not applicable. Users should upgrade to version 2.40.0 or greater to receive a a mitigation for the vulnerability.

Why it matters now

Exploitation Proof of concept CISA SSVC · not in CISA KEV
EPSS 0.04138 90th percentileScored 2026-11-07
Public exploit Yes 2 exploit referencesTagged by NVD
Fix Fixed azure-cli (Azure): 2.40.0azure-cli (PyPI): 2.40.0

SSVC decision points

CISA ADP · SSVC 2.0.3

Exploitation
Poc
Automatable
No
Technical impact
Total

The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.

Affected products

VendorProductAffected versionsFixed inStatusSource
Microsoftazure-clibefore 2.40.02.40.0Patch availableCNA
—azure-cli (PyPI)before 2.40.02.40.0Patch availableGHSA-47xc-9rr2-q7p4
  • azure-cli VendorMicrosoft Affected before 2.40.0 Fixed in 2.40.0 Patch available CNA
  • azure-cli (PyPI) Vendor— Affected before 2.40.0 Fixed in 2.40.0 Patch available GHSA-47xc-9rr2-q7p4

CPE configurations NVD · 2

CPEVersionsRoleVendor
cpe:2.3:a:microsoft:azure_command-line_interface:*:*:*:*:*:*:*:*before 2.40.0VulnerableMicrosoft
cpe:2.3:o:microsoft:windows:-:*:*:*:*:*:*:*not specified by NVDRunning onMicrosoft
  • cpe:2.3:a:microsoft:azure_command-line_interface:*:*:*:*:*:*:*:* Versions before 2.40.0 Vulnerable ·Microsoft
  • cpe:2.3:o:microsoft:windows:-:*:*:*:*:*:*:* Versions not specified by NVD Running on ·Microsoft

Remediation

  • Fix · CNA azure-cli (Azure) Fixed in 2.40.0
  • Fix · GHSA-47xc-9rr2-q7p4 azure-cli (PyPI) Fixed in 2.40.0 Advisory →

Timeline

  1. 2026-10-02 Threatist record created from CVE-2022-39327
  2. 2026-10-03 Alias added: GHSA-47xc-9rr2-q7p4
  3. 2026-10-23 EPSS moved to the 90th–95th percentile

References

  • TI-2023-18102 Azure CLI REST Command Information Disclosure Vulnerability CVSS 3.1HIGH 8.6
  • TI-2024-29220 Azure Command Line Integration (CLI) Elevation of Privilege Vulnerability CVSS 3.1CRITICAL 9.1
  • TI-2025-17811 Azure Command Line Integration (CLI) Elevation of Privilege Vulnerability CVSS 3.1HIGH 8.4

Sources