CyberSecBulletin

Improper Control of Generation of Code

CWE-94

The product constructs all or part of a code segment using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the syntax or behavior of the intended code segment.

We track 2,468 vulnerabilities of this type. 100% are rated high or critical, and the average CVSS score is 8.8. 82 have been exploited in real attacks.

How this weakness is prevented

  • Architecture and Design: Refactor your program so that you do not have to dynamically generate code.
  • Architecture and Design: Run your code in a jail or similar sandbox environment that enforces strict boundaries between the process and the operating system. This may effectively restrict which code can be executed by your product. Examples include the Unix chroot jail and AppArmor. In general, managed code may provide some protection. This may not be a feasible solution, and it only limits the impact to the operating system; the rest of your application may still be subject to compromise. Be careful to avoid CWE-243 and other weaknesses related to jails.
  • Testing: Use dynamic tools and techniques that interact with the product using large test suites with many diverse inputs, such as fuzz testing (fuzzing), robustness testing, and fault injection. The product's operation may slow down, but it should not become unstable, crash, or generate incorrect results.
  • Operation: Run the code in an environment that performs automatic taint propagation and prevents any command execution that uses tainted variables, such as Perl's -T switch. This will force the program to perform validation steps that remove the taint, although you must be careful to correctly validate your inputs so that you do not accidentally mark dangerous inputs as untainted (see CWE-183 and CWE-184).
  • Operation: Run the code in an environment that performs automatic taint propagation and prevents any command execution that uses tainted variables, such as Perl's -T switch. This will force the program to perform validation steps that remove the taint, although you must be careful to correctly validate your inputs so that you do not accidentally mark dangerous inputs as untainted (see CWE-183 and CWE-184).

Latest Improper Control of Generation of Code vulnerabilities

  • 7.0 High severity

    Red Hat Enterprise Linux 8: Improper Control of Generation of Code

    CVE-2024-6655Red Hat

    A flaw was found in the GTK library. Under certain conditions, it is possible for a library to be injected into a GTK application from the current working directory.

  • 9.9 Critical severity

    Thruk: Improper Control of Generation of Code

    CVE-2024-39915Sni

    Thruk is a multibackend monitoring webinterface for Naemon, Nagios, Icinga and Shinken using the Livestatus API. This authenticated RCE in Thruk allows authorized users with network access to inject arbitrary commands via the URL parameter during PDF report ge

  • 9.4 Critical severity

    Symantec Privileged Access Management: Improper Control of Generation of Code

    CVE-2024-36456Broadcom

    This vulnerability allows an unauthenticated attacker to achieve remote command execution on the affected PAM system by uploading a specially crafted PAM upgrade file.

  • 8.5 High severity

    langchain-experimental: Improper Control of Generation of Code

    CVE-2024-21513Langchain-experimentalEPSS 1.89%

    Versions of the package langchain-experimental from 0.0.15 and before 0.0.21 are vulnerable to Arbitrary Code Execution when retrieving values from the database, the code will attempt to call 'eval' on all values. An attacker can exploit this vulnerability and

  • 8.8 High severity

    pypa/setuptools: Improper Control of Generation of Code

    CVE-2024-6345PypaEPSS 1.94%

    A vulnerability in the package_index module of pypa/setuptools versions up to 69.1.1 allows for remote code execution via its download functions. These functions, which are used to download packages from URLs provided by users or retrieved from package index s

  • 8.8 High severity

    publiccms: Improper Control of Generation of Code

    CVE-2024-40552PublicCMS

    PublicCMS v4.0.202302.e was discovered to contain a remote commande execution (RCE) vulnerability via the cmdarray parameter at /site/ScriptComponent.java.

  • 8.8 High severity

    publiccms: Unrestricted Upload of File with Dangerous Type

    CVE-2024-40546PublicCMS

    An arbitrary file upload vulnerability in the component /admin/cmsWebFile/save of PublicCMS v4.0.202302.e allows attackers to execute arbitrary code via uploading a crafted file.

  • 8.8 High severity

    seacms: Improper Control of Generation of Code

    CVE-2024-40522SeaCMSEPSS 1.17%

    There is a remote code execution vulnerability in SeaCMS 12.9. The vulnerability is caused by phomebak.php writing some variable names passed in without filtering them before writing them into the php file. An authenticated attacker can exploit this vulnerabil

  • 8.8 High severity

    seacms: Improper Control of Generation of Code

    CVE-2024-40521SeaCMSEPSS 1.26%

    SeaCMS 12.9 has a remote code execution vulnerability. The vulnerability is due to the fact that although admin_template.php imposes certain restrictions on the edited file, attackers can still bypass the restrictions and write code in some way, allowing authe

  • 8.8 High severity

    glpi: Improper Control of Generation of Code

    CVE-2024-37149GLPI ProjectEPSS 21.1%

    GLPI is an open-source asset and IT management software package that provides ITIL Service Desk features, licenses tracking and software auditing. An authenticated technician user can upload a malicious PHP script and hijack the plugin loader to execute this m

  • 9.8 Critical severity

    smartbond_da14695: Improper Control of Generation of Code

    CVE-2024-25077Renesas

    An issue was discovered on Renesas SmartBond DA14691, DA14695, DA14697, and DA14699 devices. The Nonce used for on-the-fly decryption of flash images is stored in an unsigned header, allowing its value to be modified without invalidating the signature used for

  • 9.1 Critical severity

    14finger: Improper Control of Generation of Code

    CVE-2024-37770B1ackc4tEPSS 1.57%

    14Finger v1.1 was discovered to contain a remote command execution (RCE) vulnerability in the fingerprint function. This vulnerability allows attackers to execute arbitrary commands via a crafted payload.

  • 9.8 Critical severity

    Firefox: Improper Control of Generation of Code

    CVE-2024-6602Mozilla

    A mismatch between allocator and deallocator could have led to memory corruption. This vulnerability affects Firefox < 128, Firefox ESR < 115.13, Thunderbird < 115.13, and Thunderbird < 128.

  • 9.8 Critical severity

    Ninja Forms: Improper Control of Generation of Code

    CVE-2024-37934Saturday Drive

    Improper Control of Generation of Code ('Code Injection') vulnerability in Saturday Drive Ninja Forms allows Code Injection.This issue affects Ninja Forms: from n/a through 3.8.4.

  • 9.8 Critical severity

    Product Table for WooCommerce by WBW: Improper Control of Generation of Code

    CVE-2024-6365WoobewooEPSS 1.21%

    The Product Table by WBW plugin for WordPress is vulnerable to Remote Code Execution in all versions up to, and including, 2.0.1 via the 'saveCustomTitle' function. This is due to missing authorization and lack of sanitization of appended data in the languages

  • 9.8 Critical severity

    Apache CloudStack: Improper Control of Generation of Code

    CVE-2024-39864ApacheEPSS 1.77%

    The CloudStack integration API service allows running its unauthenticated API server (usually on port 8096 when configured and enabled via integration.api.port global setting) for internal portal integrations and for testing purposes. By default, the integrati

  • 9.8 Critical severity

    Apache CloudStack: Improper Control of Generation of Code

    CVE-2024-38346ApacheEPSS 3.3%

    The CloudStack cluster service runs on unauthenticated port (default 9090) that can be misused to run arbitrary commands on targeted hypervisors and CloudStack management server hosts. Some of these commands were found to have command injection vulnerabilities

  • 8.8 High severity

    ghostscript: Improper Control of Generation of Code

    CVE-2024-33871ArtifexEPSS 1.43%

    An issue was discovered in Artifex Ghostscript before 10.03.1. contrib/opvp/gdevopvp.c allows arbitrary code execution via a custom Driver library, exploitable via a crafted PostScript document. This occurs because the Driver parameter for opvp (and oprp) devi

  • 9.8 Critical severity

    gradio: Improper Control of Generation of Code

    CVE-2024-39236Gradio Project

    Gradio v4.36.1 was discovered to contain a code injection vulnerability via the component /gradio/component_meta.py. This vulnerability is triggered via a crafted input. NOTE: the supplier disputes this because the report is about a user attacking himself.

  • 9.8 Critical severity

    OSGeo GeoServer GeoTools Eval Injection Exploited

    CVE-2024-36401GeoServerEPSS 99.8%

    GeoServer is an open source server that allows users to share and edit geospatial data. Prior to versions 2.22.6, 2.23.6, 2.24.4, and 2.25.2, multiple OGC request parameters allow Remote Code Execution (RCE) by unauthenticated users through specially crafted i

  • 9.8 Critical severity

    MongoDB Compass: Improper Control of Generation of Code

    CVE-2024-6376MongoDB

    MongoDB Compass may be susceptible to code injection due to insufficient sandbox protection settings with the usage of ejson shell parser in Compass' connection handling. This issue affects MongoDB Compass versions prior to version 1.42.2

  • 9.8 Critical severity

    agreejs_shared: Improper Control of Generation of Code

    CVE-2024-39017Agreejs Shared

    agreejs shared v0.0.1 was discovered to contain a prototype pollution via the function mergeInternalComponents. This vulnerability allows attackers to execute arbitrary code or cause a Denial of Service (DoS) via injecting arbitrary properties.

  • 9.8 Critical severity

    hod: Improper Control of Generation of Code

    CVE-2024-39015Cafebazaar

    cafebazaar hod v0.4.14 was discovered to contain a prototype pollution via the function request. This vulnerability allows attackers to execute arbitrary code or cause a Denial of Service (DoS) via injecting arbitrary properties.

  • 9.8 Critical severity

    jsonic-next: Improper Control of Generation of Code

    CVE-2024-38993Rjrodger

    rjrodger jsonic-next v2.12.1 was discovered to contain a prototype pollution via the function empty. This vulnerability allows attackers to execute arbitrary code or cause a Denial of Service (DoS) via injecting arbitrary properties.

  • 7.2 High severity

    cososys_endpoint_protector: Improper Control of Generation of Code

    CVE-2024-36074Netwrix

    Netwrix CoSoSys Endpoint Protector through 5.9.3 and CoSoSys Unify through 7.0.6 contain a remote code execution vulnerability in the Endpoint Protector and Unify agent in the way that the EasyLock dependency is acquired from the server. An attacker with admin

  • 7.5 High severity

    h2oai/h2o-3: Improper Control of Generation of Code

    CVE-2024-5979H2oai

    In h2oai/h2o-3 version 3.46.0, the `run_tool` command in the `rapids` component allows the `main` function of any class under the `water.tools` namespace to be called. One such class, `MojoConvertTool`, crashes the server when invoked with an invalid argument,

  • 9.8 Critical severity

    vanna-ai/vanna: Improper Control of Generation of Code

    CVE-2024-5826Vanna-ai

    In the latest version of vanna-ai/vanna, the `vanna.ask` function is vulnerable to remote code execution due to prompt injection. The root cause is the lack of a sandbox when executing LLM-generated code, allowing an attacker to manipulate the code executed by

  • 9.8 Critical severity

    berriai/litellm: Improper Control of Generation of Code

    CVE-2024-5751BerriAI

    BerriAI/litellm version v1.35.8 contains a vulnerability where an attacker can achieve remote code execution. The vulnerability exists in the `add_deployment` function, which decodes and decrypts environment variables from base64 and assigns them to `os.enviro

  • 9.8 Critical severity

    iam: Improper Control of Generation of Code

    CVE-2024-39669Soffid

    In the Console in Soffid IAM before 3.5.39, necessary checks were not applied to some Java objects. A malicious agent could possibly execute arbitrary code in the Sync Server and compromise security.

  • 8.4 High severity

    ntpl-xpon1gfevn_firmware: Improper Control of Generation of Code

    CVE-2024-37855Nepstech

    An issue in Nepstech Wifi Router xpon (terminal) NTPL-Xpon1GFEVN, hardware verstion 1.0 firmware 2.0.1 allows a remote attacker to execute arbitrary code via the router's Telnet port 2345 without requiring authentication credentials.

  • 7.5 High severity

    HPE Athonet Mobile Core: Improper Control of Generation of Code

    CVE-2024-6206Hewlett Packard Enterprise

    A security vulnerability has been identified in HPE Athonet Mobile Core software. The core application contains a code injection vulnerability where a threat actor could execute arbitrary commands with the privilege of the underlying container leading to compl

  • 9.8 Critical severity

    WhatsUp Gold: Improper Neutralization of Special Elements used in a Command

    CVE-2024-4884Progress SoftwareEPSS 24.3%

    In WhatsUp Gold versions released before 2023.1.3, an unauthenticated Remote Code Execution vulnerability in Progress WhatsUpGold. The Apm.UI.Areas.APM.Controllers.CommunityController allows execution of commands with iisapppool\nmconsole privileges.

  • 9.8 Critical severity

    WhatsUp Gold: Improper Neutralization of Special Elements used in a Command

    CVE-2024-4883Progress SoftwareEPSS 64.5%

    In WhatsUp Gold versions released before 2023.1.3, a Remote Code Execution issue exists in Progress WhatsUp Gold. This vulnerability allows an unauthenticated attacker to achieve the RCE as a service account through NmApi.exe.

  • 10.0 Critical severity

    m4_pdf: Improper Control of Generation of Code

    CVE-2023-50029PrestaShop

    PHP Injection vulnerability in the module "M4 PDF Extensions" (m4pdf) up to version 3.3.2 from PrestaAddons for PrestaShop allows attackers to run arbitrary code via the M4PDF::saveTemplate() method.

  • 8.8 High severity

    WishList Member X: Improper Control of Generation of Code

    CVE-2024-37109Membership Software

    Improper Control of Generation of Code ('Code Injection') vulnerability in Membership Software WishList Member X allows Code Injection.This issue affects WishList Member X: from n/a before 3.26.7.

  • 9.8 Critical severity

    Business Process Manangement (BPM): Improper Control of Generation of Code

    CVE-2024-5683Next4Biz CRM & BPM Software

    Improper Control of Generation of Code ('Code Injection') vulnerability in Next4Biz CRM & BPM Software Business Process Manangement (BPM) allows Remote Code Inclusion. This issue affects Business Process Manangement (BPM): from 6.6.4.4 before 6.6.4.5.

  • 9.8 Critical severity

    emacs: Improper Control of Generation of Code

    CVE-2024-39331GNUEPSS 1.31%

    In Emacs before 29.4, org-link-expand-abbrev in lisp/ol.el expands a %(...) link abbrev even when it specifies an unsafe function, such as shell-command-to-string. This affects Org Mode before 9.7.5.

  • 8.8 High severity

    Security SOAR: Improper Control of Generation of Code

    CVE-2024-38319IBM

    IBM Security SOAR 51.0.2.0 could allow an authenticated user to execute malicious code loaded from a specially crafted script. IBM X-Force ID: 294830.

  • 9.0 Critical severity

    joplin: Improper Control of Generation of Code

    CVE-2023-45673Laurent22EPSS 1.03%

    Joplin is a free, open source note taking and to-do application. A remote code execution (RCE) vulnerability in affected versions allows clicking on a link in a PDF in an untrusted note to execute arbitrary shell commands. Clicking links in PDFs allows for arb

  • 8.0 High severity

    xwiki-platform: Improper Control of Generation of Code

    CVE-2024-37899XWiki

    XWiki Platform is a generic wiki platform offering runtime services for applications built on top of it. When an admin disables a user account, the user's profile is executed with the admin's rights. This allows a user to place malicious code in the user profi