CVE Vulnerabilities

CVE-2021-1443

Improper Neutralization of Special Elements used in a Command ('Command Injection')

Published: Mar 24, 2021 | Modified: Nov 21, 2024
CVSS 3.x
7.2
HIGH
Source:
NVD
CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H
CVSS 2.x
8.5 HIGH
AV:N/AC:M/Au:S/C:C/I:C/A:C
RedHat/V2
RedHat/V3
Ubuntu

A vulnerability in the web UI of Cisco IOS XE Software could allow an authenticated, remote attacker to execute arbitrary code with root privileges on the underlying operating system of an affected device. The vulnerability exists because the affected software improperly sanitizes values that are parsed from a specific configuration file. An attacker could exploit this vulnerability by tampering with a specific configuration file and then sending an API call. A successful exploit could allow the attacker to inject arbitrary code that would be executed on the underlying operating system of the affected device. To exploit this vulnerability, the attacker would need to have a privileged set of credentials to the device.

Weakness

The product constructs all or part of a command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended command when it is sent to a downstream component.

Affected Software

Name Vendor Start Version End Version
Ios_xe Cisco 16.9.1 (including) 16.9.1 (including)
Ios_xe Cisco 16.9.1a (including) 16.9.1a (including)
Ios_xe Cisco 16.9.1b (including) 16.9.1b (including)
Ios_xe Cisco 16.9.1c (including) 16.9.1c (including)
Ios_xe Cisco 16.9.1d (including) 16.9.1d (including)
Ios_xe Cisco 16.9.1s (including) 16.9.1s (including)
Ios_xe Cisco 16.9.2 (including) 16.9.2 (including)
Ios_xe Cisco 16.9.2a (including) 16.9.2a (including)
Ios_xe Cisco 16.9.2s (including) 16.9.2s (including)
Ios_xe Cisco 16.9.3 (including) 16.9.3 (including)
Ios_xe Cisco 16.9.3a (including) 16.9.3a (including)
Ios_xe Cisco 16.9.3h (including) 16.9.3h (including)
Ios_xe Cisco 16.9.3s (including) 16.9.3s (including)
Ios_xe Cisco 16.9.4 (including) 16.9.4 (including)
Ios_xe Cisco 16.9.4c (including) 16.9.4c (including)
Ios_xe Cisco 16.9.5 (including) 16.9.5 (including)
Ios_xe Cisco 16.9.5f (including) 16.9.5f (including)
Ios_xe Cisco 16.10.1 (including) 16.10.1 (including)
Ios_xe Cisco 16.10.1a (including) 16.10.1a (including)
Ios_xe Cisco 16.10.1b (including) 16.10.1b (including)
Ios_xe Cisco 16.10.1c (including) 16.10.1c (including)
Ios_xe Cisco 16.10.1d (including) 16.10.1d (including)
Ios_xe Cisco 16.10.1e (including) 16.10.1e (including)
Ios_xe Cisco 16.10.1f (including) 16.10.1f (including)
Ios_xe Cisco 16.10.1g (including) 16.10.1g (including)
Ios_xe Cisco 16.10.1s (including) 16.10.1s (including)
Ios_xe Cisco 16.10.2 (including) 16.10.2 (including)
Ios_xe Cisco 16.10.3 (including) 16.10.3 (including)
Ios_xe Cisco 16.11.1 (including) 16.11.1 (including)
Ios_xe Cisco 16.11.1a (including) 16.11.1a (including)
Ios_xe Cisco 16.11.1b (including) 16.11.1b (including)
Ios_xe Cisco 16.11.1c (including) 16.11.1c (including)
Ios_xe Cisco 16.11.1s (including) 16.11.1s (including)
Ios_xe Cisco 16.11.2 (including) 16.11.2 (including)
Ios_xe Cisco 16.12.1 (including) 16.12.1 (including)
Ios_xe Cisco 16.12.1a (including) 16.12.1a (including)
Ios_xe Cisco 16.12.1c (including) 16.12.1c (including)
Ios_xe Cisco 16.12.1s (including) 16.12.1s (including)
Ios_xe Cisco 16.12.1t (including) 16.12.1t (including)
Ios_xe Cisco 16.12.1w (including) 16.12.1w (including)
Ios_xe Cisco 16.12.1x (including) 16.12.1x (including)
Ios_xe Cisco 16.12.1y (including) 16.12.1y (including)
Ios_xe Cisco 16.12.1z (including) 16.12.1z (including)
Ios_xe Cisco 16.12.1z1 (including) 16.12.1z1 (including)
Ios_xe Cisco 16.12.1za (including) 16.12.1za (including)
Ios_xe Cisco 16.12.2 (including) 16.12.2 (including)
Ios_xe Cisco 16.12.2a (including) 16.12.2a (including)
Ios_xe Cisco 16.12.2s (including) 16.12.2s (including)
Ios_xe Cisco 16.12.2t (including) 16.12.2t (including)
Ios_xe Cisco 16.12.3 (including) 16.12.3 (including)
Ios_xe Cisco 16.12.3a (including) 16.12.3a (including)
Ios_xe Cisco 16.12.3s (including) 16.12.3s (including)
Ios_xe Cisco 17.1.1 (including) 17.1.1 (including)
Ios_xe Cisco 17.1.1a (including) 17.1.1a (including)
Ios_xe Cisco 17.1.1s (including) 17.1.1s (including)
Ios_xe Cisco 17.1.1t (including) 17.1.1t (including)
Ios_xe Cisco 17.1.2 (including) 17.1.2 (including)
Ios_xe Cisco 17.2.1 (including) 17.2.1 (including)
Ios_xe Cisco 17.2.1a (including) 17.2.1a (including)
Ios_xe Cisco 17.2.1r (including) 17.2.1r (including)
Ios_xe Cisco 17.2.1v (including) 17.2.1v (including)

Extended Description

Command injection vulnerabilities typically occur when:

Many protocols and products have their own custom command language. While OS or shell command strings are frequently discovered and targeted, developers may not realize that these other command languages might also be vulnerable to attacks. Command injection is a common problem with wrapper programs.

Potential Mitigations

  • Assume all input is malicious. Use an “accept known good” input validation strategy, i.e., use a list of acceptable inputs that strictly conform to specifications. Reject any input that does not strictly conform to specifications, or transform it into something that does.
  • When performing input validation, consider all potentially relevant properties, including length, type of input, the full range of acceptable values, missing or extra inputs, syntax, consistency across related fields, and conformance to business rules. As an example of business rule logic, “boat” may be syntactically valid because it only contains alphanumeric characters, but it is not valid if the input is only expected to contain colors such as “red” or “blue.”
  • Do not rely exclusively on looking for malicious or malformed inputs. This is likely to miss at least one undesirable input, especially if the code’s environment changes. This can give attackers enough room to bypass the intended validation. However, denylists can be useful for detecting potential attacks or determining which inputs are so malformed that they should be rejected outright.

References