Skip to content
OpenAdvisories

Weakness (CWE)

CWE-77: Command Injection

Class Draft Improper Neutralization of Special Elements used in a Command

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.

More detail

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.

How to prevent it (5 mitigations)
  1. Architecture and Design

    If at all possible, use library calls rather than external processes to recreate the desired functionality.

  2. Implementation

    If possible, ensure that all external commands called from the program are statically created.

  3. Implementation

    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.

  4. Operation

    Run time: Run time policy enforcement may be used in an allowlist fashion to prevent use of any non-sanctioned commands.

  5. System Configuration

    Assign permissions that prevent the user from accessing/opening privileged files.

Source: MITRE CWE-77

1,207 results · Clear filters · Feed

  • High 8.4

    HashiCorp go-getter Vulnerable to Code Execution On Git Update Via Git Config Manipulation

    HashiCorp’s go-getter library can be coerced into executing Git update on an existing maliciously modified Git Configuration, potentially leading to arbitrary code execution.

  • High 7.1

    OnCell G3470A-LTE Series: Authenticated Command Injection via webDelIPSec

    OnCell G3470A-LTE Series firmware versions v1.7.7 and prior have been identified as vulnerable due to a lack of neutralized inputs in IPSec configuration. An attacker could modify the intended commands sent to target functions, which could cause malicious use…

  • High 7.1

    OnCell G3470A-LTE Series: Authenticated Command Injection via webUploadKey

    OnCell G3470A-LTE Series firmware versions v1.7.7 and prior have been identified as vulnerable due to a lack of neutralized inputs in the web key upload function. An attacker could modify the intended commands sent to target functions, which could cause malic…

  • High 8.9

    Bludit - Remote Code Execution (RCE) through Image API

    A security vulnerability has been identified in Bludit, allowing authenticated attackers to execute arbitrary code through the Image API. This vulnerability arises from improper handling of file uploads, enabling malicious actors to upload and execute PHP fil…

  • High 8.9

    Bludit - Remote Code Execution (RCE) through File API

    A security vulnerability has been identified in Bludit, allowing attackers with knowledge of the API token to upload arbitrary files through the File API which leads to arbitrary code execution on the server. This vulnerability arises from improper handling o…

  • High 8.8
    CVE-2024-35242 Public exploit

    Composer vulnerable to command injection via malicious git/hg branch names

    Composer is a dependency manager for PHP. On the 2.x branch prior to versions 2.2.24 and 2.7.7, the `composer install` command running inside a git/hg repository which has specially crafted branch names can lead to command injection. This requires cloning unt…

  • High 8.8

    Composer vulnerable to command injection via malicious git branch name

    Composer is a dependency manager for PHP. On the 2.x branch prior to versions 2.2.24 and 2.7.7, the `status`, `reinstall` and `remove` commands with packages installed from source via git containing specially crafted branch names in the repository can be used…

  • High 8.8

    On Mitel 6869i 4.5.0.41 devices, the Manual Firmware Update (upgrade.html) page does not perform sanitization on the us…

  • High 8.3

    An issue was discovered on Mitel 6869i through 4.5.0.41 and 5.x through 5.0.0.1018 devices. A command injection vulnera…

  • High 8.1
    CVE-2024-5565 EPSS 15%

    Prompt Injection in "ask" API with visualization leads to RCE

    The Vanna library uses a prompt function to present the user with visualized results, it is possible to alter the prompt using prompt injection and run arbitrary Python code instead of the intended visualization code. Specifically - allowing external input to…

  • High 8.8
    CVE-2024-35397 EPSS 15%

    TOTOLINK CP900L v4.1.5cu.798_B20221228 weas discovered to contain a command injection vulnerability in the NTPSyncWithH…

  • High 8.8

    TP-Link Archer C5400X - RFTest Unauthenticated Command Injection

    The affected device expose a network service called "rftest" that is vulnerable to unauthenticated command injection on ports TCP/8888, TCP/8889, and TCP/8890. By successfully exploiting this flaw, remote unauthenticated attacker can gain arbitrary command ex…

  • High 8.6

    Tenda FH1206 V1.2.0.8(8155) was discovered to contain a command injection vulnerability via the cmdinput parameter at i…

  • High 8.4

    Remote Code Execution in parisneo/lollms-webui

    A remote code execution (RCE) vulnerability exists in the parisneo/lollms-webui, specifically within the 'open_file' module, version 9.5. The vulnerability arises due to improper neutralization of special elements used in a command within the 'open_file' func…

  • High 7.8

    Local Code Injection Vulnerability in AuthPoint Password Manager App for macOS Safari

    Improper Neutralization of Special Elements used in a Command ('Command Injection') vulnerability in WatchGuard AuthPoint Password Manager on MacOS allows an a adversary with local access to execute code under the context of the AuthPoint Password Manager app…

  • High 7.8

    A vulnerability in the ConfD CLI and the Cisco Crosswork Network Services Orchestrator CLI could allow an authenticated…

  • High 7.8

    Remote Code Execution vulnerability in the iManager

    Remote Code Execution has been discovered in OpenText™ iManager 3.2.6.0200. The vulnerability can trigger command injection and insecure deserialization issues.

  • High 8.0

    TOTOLINK X5000R V9.1.0cu.2350_B20230313 was discovered to contain a command injection vulnerability via the 'password' …

  • High 7.2

    A vulnerability has been identified in CPCI85 Central Processing/Communication (All versions < V5.30), SICORE Base syst…

  • High 7.8

    PHOENIX CONTACT: command injection gains root privileges using the OCPP remote service

    A local attacker with low privileges can use a command injection vulnerability to gain root privileges due to improper input validation using the OCPP Remote service.

  • High 7.8

    Arbitrary File Creation in PaperCut NG/MF Web Print Image Handler

    An arbitrary file creation vulnerability exists in PaperCut NG/MF that only affects Windows servers with Web Print enabled. This specific flaw exists within the image-handler process, which can incorrectly create files that don’t exist when a maliciously form…

  • High 7.8

    The issue was addressed with improved memory handling. This issue is fixed in iOS 16.7.8 and iPadOS 16.7.8, iOS 17.5 an…

  • High 7.2

    Tenda O3V2 with firmware versions V1.0.0.10 and V1.0.0.12 was discovered to contain a Blind Command Injection via dest …

  • High 8.4

    @hoppscotch/cli affected by Sandbox Escape in @hoppscotch/js-sandbox leads to RCE

    @hoppscotch/cli is a CLI to run Hoppscotch Test Scripts in CI environments. Prior to 0.8.0, the @hoppscotch/js-sandbox package provides a Javascript sandbox that uses the Node.js vm module. However, the vm module is not safe for sandboxing untrusted Javascrip…

  • High 8.0

    Linksys E5600 v1.1.0.26 was discovered to contain a command injection vulnerability via the PinCode parameter at /API/i…

  • High 7.5

    D-Link DIR-845L router v1.01KRb03 and before is vulnerable to Command injection via the hnap_main()func.

  • High 7.2

    Cri-o: arbitrary command injection via pod annotation

    A flaw was found in cri-o, where an arbitrary systemd property can be injected via a Pod annotation. Any user who can create a pod with an arbitrary annotation may perform an arbitrary action on the host system.

  • High 7.5

    D-Link DIR-822+ V1.0.5 was found to contain a command injection in SetPlcNetworkpwd function of prog.cgi, which allows …

  • High 7.5

    Improper verification of a user input in Open Source MANO v7-v12 allows an authenticated attacker to execute arbitrary …

  • High 8.1

    A Heap Overflow vulnerability in WLInfoRailService component of Ivanti Avalanche before 6.4.3 allows a remote unauthent…

  • High 7.3

    Tenda FH1203 V2.0.1.6 firmware has a command injection vulnerablility in formexeCommand function via the cmdinput param…

  • High 8.8

    Tenda W30E v1.0 V1.0.1.25(633) firmware contains a command injection vulnerablility in the formexeCommand function via …

  • High 8.8

    Tenda AC7V1.0 v15.03.06.44 firmware contains a command injection vulnerablility in formexeCommand function via the cmdi…

  • High 8.8

    Command injection vulnerability in PLANEX COMMUNICATIONS wireless LAN routers allows a network-adjacent unauthenticated…

  • High 7.8

    Insecure default configurations in Hikvision Interactive Tablet DS-D5B86RB/B V2.3.0 build220119, allows attackers to ex…

  • High 8.8
    CVE-2024-29269 Public exploit Scanner template

    An issue discovered in Telesquare TLR-2005Ksh 1.0.0 and 1.1.4 allows attackers to run arbitrary system commands via the…

  • High 8.8

    Pods - Custom Content Types and Fields - Authenticated (Contributor+) Remote Code Execution

    The Pods – Custom Content Types and Fields plugin for WordPress is vulnerable to Remote Code Exxecution via shortcode in all versions up to, and including, 3.0.10 (with the exception of 2.7.31.2, 2.8.23.2, 2.9.19.2). This makes it possible for authenticated a…

  • High 7.2

    Microsoft Defender for IoT Remote Code Execution Vulnerability

    Microsoft Defender for IoT Remote Code Execution Vulnerability

  • High 8.0

    TOTOLINK EX200 V4.0.3c.7646_B20201211 was discovered to contain a remote code execution (RCE) vulnerability via the lan…

  • High 8.8

    A command injection vulnerability exists in /goform/exeCommand in Tenda AC18 v15.03.05.05, which allows attackers to co…