CWE-94
Allowed-with-ReviewImproper Control of Generation of Code ('Code Injection')
Abstraction: Base · Status: Draft
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.
8400 vulnerabilities reference this CWE, most recent first.
GHSA-58FM-M7HR-HVWC
Vulnerability from github – Published: 2022-05-17 00:39 – Updated: 2022-05-17 00:39PHP remote file inclusion vulnerability in social_game_play.php in Social Site Generator (SSG) 2.0 allows remote attackers to execute arbitrary PHP code via a URL in the path parameter.
{
"affected": [],
"aliases": [
"CVE-2008-6421"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2009-03-06T18:30:00Z",
"severity": "HIGH"
},
"details": "PHP remote file inclusion vulnerability in social_game_play.php in Social Site Generator (SSG) 2.0 allows remote attackers to execute arbitrary PHP code via a URL in the path parameter.",
"id": "GHSA-58fm-m7hr-hvwc",
"modified": "2022-05-17T00:39:34Z",
"published": "2022-05-17T00:39:34Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2008-6421"
},
{
"type": "WEB",
"url": "https://exchange.xforce.ibmcloud.com/vulnerabilities/42780"
},
{
"type": "WEB",
"url": "https://www.exploit-db.com/exploits/5707"
},
{
"type": "WEB",
"url": "http://osvdb.org/45865"
},
{
"type": "WEB",
"url": "http://secunia.com/advisories/30462"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/bid/29462"
}
],
"schema_version": "1.4.0",
"severity": []
}
GHSA-58JX-V4Q9-WGXJ
Vulnerability from github – Published: 2022-05-01 18:05 – Updated: 2022-05-01 18:05PHP remote file inclusion vulnerability in watermark.php in the vm (aka Jean-Francois Laflamme) watermark 0.4.1 mod for Gallery allows remote attackers to execute arbitrary PHP code via a URL in the GALLERY_BASEDIR parameter.
{
"affected": [],
"aliases": [
"CVE-2007-2575"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2007-05-09T21:19:00Z",
"severity": "HIGH"
},
"details": "PHP remote file inclusion vulnerability in watermark.php in the vm (aka Jean-Francois Laflamme) watermark 0.4.1 mod for Gallery allows remote attackers to execute arbitrary PHP code via a URL in the GALLERY_BASEDIR parameter.",
"id": "GHSA-58jx-v4q9-wgxj",
"modified": "2022-05-01T18:05:07Z",
"published": "2022-05-01T18:05:07Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2007-2575"
},
{
"type": "WEB",
"url": "https://exchange.xforce.ibmcloud.com/vulnerabilities/34112"
},
{
"type": "WEB",
"url": "https://www.exploit-db.com/exploits/3857"
},
{
"type": "WEB",
"url": "http://osvdb.org/37655"
},
{
"type": "WEB",
"url": "http://www.vupen.com/english/advisories/2007/1674"
}
],
"schema_version": "1.4.0",
"severity": []
}
GHSA-58M2-C5RP-JR5W
Vulnerability from github – Published: 2022-05-24 19:20 – Updated: 2022-07-29 00:00The Similar Posts WordPress plugin through 3.1.5 allow high privilege users to execute arbitrary PHP code in an hardened environment (ie with DISALLOW_FILE_EDIT, DISALLOW_FILE_MODS and DISALLOW_UNFILTERED_HTML set to true) via the 'widget_rrm_similar_posts_condition' widget setting of the plugin.
{
"affected": [],
"aliases": [
"CVE-2021-24537"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2021-11-08T18:15:00Z",
"severity": "HIGH"
},
"details": "The Similar Posts WordPress plugin through 3.1.5 allow high privilege users to execute arbitrary PHP code in an hardened environment (ie with DISALLOW_FILE_EDIT, DISALLOW_FILE_MODS and DISALLOW_UNFILTERED_HTML set to true) via the \u0027widget_rrm_similar_posts_condition\u0027 widget setting of the plugin.",
"id": "GHSA-58m2-c5rp-jr5w",
"modified": "2022-07-29T00:00:48Z",
"published": "2022-05-24T19:20:01Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2021-24537"
},
{
"type": "WEB",
"url": "https://wpscan.com/vulnerability/0d6b46cb-5244-486f-ad70-4023907ac9eb"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-58M3-RCVP-F9WW
Vulnerability from github – Published: 2024-06-27 21:32 – Updated: 2025-10-15 15:48In 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, causing a denial of service.
{
"affected": [
{
"package": {
"ecosystem": "PyPI",
"name": "h2o"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"last_affected": "3.46.0"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2024-5979"
],
"database_specific": {
"cwe_ids": [
"CWE-400",
"CWE-94"
],
"github_reviewed": true,
"github_reviewed_at": "2024-06-28T21:09:00Z",
"nvd_published_at": "2024-06-27T19:15:18Z",
"severity": "HIGH"
},
"details": "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, causing a denial of service.",
"id": "GHSA-58m3-rcvp-f9ww",
"modified": "2025-10-15T15:48:42Z",
"published": "2024-06-27T21:32:08Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2024-5979"
},
{
"type": "WEB",
"url": "https://github.com/h2oai/h2o-3/commit/d0899f8e0f7a584b60405a65b1d7b439aaaa55a5"
},
{
"type": "PACKAGE",
"url": "https://github.com/h2oai/h2o-3"
},
{
"type": "WEB",
"url": "https://huntr.com/bounties/d80a2139-fc03-44b7-b739-de41e323b458"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H",
"type": "CVSS_V3"
}
],
"summary": "h2o vulnerable to unexpected POST request shutting down server"
}
GHSA-58M6-PV72-6X4G
Vulnerability from github – Published: 2022-05-01 07:10 – Updated: 2022-05-01 07:10PHP remote file inclusion vulnerability in extcalendar.php in Mohamed Moujami ExtCalendar 2.0 allows remote attackers to execute arbitrary PHP code via a URL in the mosConfig_absolute_path parameter.
{
"affected": [],
"aliases": [
"CVE-2006-3556"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2006-07-13T00:05:00Z",
"severity": "MODERATE"
},
"details": "PHP remote file inclusion vulnerability in extcalendar.php in Mohamed Moujami ExtCalendar 2.0 allows remote attackers to execute arbitrary PHP code via a URL in the mosConfig_absolute_path parameter.",
"id": "GHSA-58m6-pv72-6x4g",
"modified": "2022-05-01T07:10:15Z",
"published": "2022-05-01T07:10:15Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2006-3556"
},
{
"type": "WEB",
"url": "https://exchange.xforce.ibmcloud.com/vulnerabilities/27633"
},
{
"type": "WEB",
"url": "http://advisories.echo.or.id/adv/adv36-matdhule-2006.txt"
},
{
"type": "WEB",
"url": "http://securityreason.com/securityalert/1227"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/archive/1/439451/100/0/threaded"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/archive/1/440451/100/0/threaded"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/archive/1/440870/100/0/threaded"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/bid/18876"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/bid/19042"
},
{
"type": "WEB",
"url": "http://www.vupen.com/english/advisories/2006/2711"
}
],
"schema_version": "1.4.0",
"severity": []
}
GHSA-58QR-RCGV-642V
Vulnerability from github – Published: 2026-03-25 21:07 – Updated: 2026-03-25 21:07Impact
An authenticated user with permission to create or modify workflows could use the Merge node's "Combine by SQL" mode to read local files on the n8n host and achieve remote code execution. The AlaSQL sandbox did not sufficiently restrict certain SQL statements, allowing an attacker to access sensitive files on the server or even compromise the intance.
Patches
The issue has been fixed in n8n versions 2.14.1, 2.13.3, and 1.123.27. Users should upgrade to one of these versions or later to remediate the vulnerability.
Workarounds
If upgrading is not immediately possible, administrators should consider the following temporary mitigations:
- Limit workflow creation and editing permissions to fully trusted users only.
- Disable the Merge node by adding n8n-nodes-base.merge to the NODES_EXCLUDE environment variable.
These workarounds do not fully remediate the risk and should only be used as short-term mitigation measures.
{
"affected": [
{
"package": {
"ecosystem": "npm",
"name": "n8n"
},
"ranges": [
{
"events": [
{
"introduced": "2.14.0"
},
{
"fixed": "2.14.1"
}
],
"type": "ECOSYSTEM"
}
],
"versions": [
"2.14.0"
]
},
{
"package": {
"ecosystem": "npm",
"name": "n8n"
},
"ranges": [
{
"events": [
{
"introduced": "2.0.0-rc.0"
},
{
"fixed": "2.13.3"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"package": {
"ecosystem": "npm",
"name": "n8n"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "1.123.27"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-33660"
],
"database_specific": {
"cwe_ids": [
"CWE-89",
"CWE-94"
],
"github_reviewed": true,
"github_reviewed_at": "2026-03-25T21:07:45Z",
"nvd_published_at": "2026-03-25T18:16:32Z",
"severity": "CRITICAL"
},
"details": "## Impact\nAn authenticated user with permission to create or modify workflows could use the Merge node\u0027s \"Combine by SQL\" mode to read local files on the n8n host and achieve remote code execution. The AlaSQL sandbox did not sufficiently restrict certain SQL statements, allowing an attacker to access sensitive files on the server or even compromise the intance.\n\n## Patches\nThe issue has been fixed in n8n versions 2.14.1, 2.13.3, and 1.123.27. Users should upgrade to one of these versions or later to remediate the vulnerability.\n\n## Workarounds\nIf upgrading is not immediately possible, administrators should consider the following temporary mitigations:\n- Limit workflow creation and editing permissions to fully trusted users only.\n- Disable the Merge node by adding `n8n-nodes-base.merge` to the `NODES_EXCLUDE` environment variable.\n\nThese workarounds do not fully remediate the risk and should only be used as short-term mitigation measures.",
"id": "GHSA-58qr-rcgv-642v",
"modified": "2026-03-25T21:07:45Z",
"published": "2026-03-25T21:07:45Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/n8n-io/n8n/security/advisories/GHSA-58qr-rcgv-642v"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-33660"
},
{
"type": "PACKAGE",
"url": "https://github.com/n8n-io/n8n"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H",
"type": "CVSS_V3"
},
{
"score": "CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H",
"type": "CVSS_V4"
}
],
"summary": "n8n has Multiple Remote Code Execution Vulnerabilities in Merge Node AlaSQL SQL Mode"
}
GHSA-58RH-XRX9-J32V
Vulnerability from github – Published: 2022-05-01 23:44 – Updated: 2022-05-01 23:44Static code injection vulnerability in admin.php in LokiCMS 0.3.3 and earlier allows remote attackers to inject arbitrary PHP code into includes/Config.php via the default parameter.
{
"affected": [],
"aliases": [
"CVE-2008-1860"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2008-04-17T19:05:00Z",
"severity": "HIGH"
},
"details": "Static code injection vulnerability in admin.php in LokiCMS 0.3.3 and earlier allows remote attackers to inject arbitrary PHP code into includes/Config.php via the default parameter.",
"id": "GHSA-58rh-xrx9-j32v",
"modified": "2022-05-01T23:44:17Z",
"published": "2022-05-01T23:44:17Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2008-1860"
},
{
"type": "WEB",
"url": "https://exchange.xforce.ibmcloud.com/vulnerabilities/41736"
},
{
"type": "WEB",
"url": "https://www.exploit-db.com/exploits/5408"
},
{
"type": "WEB",
"url": "http://secunia.com/advisories/29749"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/archive/1/492877/100/0/threaded"
},
{
"type": "WEB",
"url": "http://www.vupen.com/english/advisories/2008/1162/references"
}
],
"schema_version": "1.4.0",
"severity": []
}
GHSA-58VV-5M7H-6GMW
Vulnerability from github – Published: 2026-03-25 18:31 – Updated: 2026-03-25 21:30Improper Control of Generation of Code ('Code Injection') vulnerability in Themeisle Woody ad snippets insert-php allows Code Injection.This issue affects Woody ad snippets: from n/a through <= 2.7.1.
{
"affected": [],
"aliases": [
"CVE-2026-25366"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2026-03-25T17:16:47Z",
"severity": "CRITICAL"
},
"details": "Improper Control of Generation of Code (\u0027Code Injection\u0027) vulnerability in Themeisle Woody ad snippets insert-php allows Code Injection.This issue affects Woody ad snippets: from n/a through \u003c= 2.7.1.",
"id": "GHSA-58vv-5m7h-6gmw",
"modified": "2026-03-25T21:30:34Z",
"published": "2026-03-25T18:31:51Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-25366"
},
{
"type": "WEB",
"url": "https://patchstack.com/database/Wordpress/Plugin/insert-php/vulnerability/wordpress-woody-ad-snippets-plugin-2-7-1-remote-code-execution-rce-vulnerability?_s_id=cve"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-5926-QQG4-957H
Vulnerability from github – Published: 2022-05-17 01:17 – Updated: 2025-04-20 03:34Improper control of generation of code vulnerability in Intel Security VirusScan Enterprise Linux (VSEL) 2.0.3 (and earlier) allows remote authenticated users to execute arbitrary code via a crafted HTTP request parameter.
{
"affected": [],
"aliases": [
"CVE-2016-8020"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2017-03-14T22:59:00Z",
"severity": "HIGH"
},
"details": "Improper control of generation of code vulnerability in Intel Security VirusScan Enterprise Linux (VSEL) 2.0.3 (and earlier) allows remote authenticated users to execute arbitrary code via a crafted HTTP request parameter.",
"id": "GHSA-5926-qqg4-957h",
"modified": "2025-04-20T03:34:05Z",
"published": "2022-05-17T01:17:42Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2016-8020"
},
{
"type": "WEB",
"url": "https://kc.mcafee.com/corporate/index?page=content\u0026id=SB10181"
},
{
"type": "WEB",
"url": "https://www.exploit-db.com/exploits/40911"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/bid/94823"
},
{
"type": "WEB",
"url": "http://www.securitytracker.com/id/1037433"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.0/AV:N/AC:H/PR:H/UI:N/S:C/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-599F-7C49-W659
Vulnerability from github – Published: 2022-10-13 19:00 – Updated: 2022-10-17 17:34Apache Commons Text performs variable interpolation, allowing properties to be dynamically evaluated and expanded. The standard format for interpolation is "${prefix:name}", where "prefix" is used to locate an instance of org.apache.commons.text.lookup.StringLookup that performs the interpolation. Starting with version 1.5 and continuing through 1.9, the set of default Lookup instances included interpolators that could result in arbitrary code execution or contact with remote servers. These lookups are: - "script" - execute expressions using the JVM script execution engine (javax.script) - "dns" - resolve dns records - "url" - load values from urls, including from remote servers Applications using the interpolation defaults in the affected versions may be vulnerable to remote code execution or unintentional contact with remote servers if untrusted configuration values are used. Users are recommended to upgrade to Apache Commons Text 1.10.0, which disables the problematic interpolators by default.
{
"affected": [
{
"package": {
"ecosystem": "Maven",
"name": "org.apache.commons:commons-text"
},
"ranges": [
{
"events": [
{
"introduced": "1.5"
},
{
"fixed": "1.10.0"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"package": {
"ecosystem": "Maven",
"name": "com.guicedee.services:commons-text"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"last_affected": "1.2.2.1-jre17"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2022-42889"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": true,
"github_reviewed_at": "2022-10-13T20:22:17Z",
"nvd_published_at": "2022-10-13T13:15:00Z",
"severity": "CRITICAL"
},
"details": "Apache Commons Text performs variable interpolation, allowing properties to be dynamically evaluated and expanded. The standard format for interpolation is \"${prefix:name}\", where \"prefix\" is used to locate an instance of org.apache.commons.text.lookup.StringLookup that performs the interpolation. Starting with version 1.5 and continuing through 1.9, the set of default Lookup instances included interpolators that could result in arbitrary code execution or contact with remote servers. These lookups are: - \"script\" - execute expressions using the JVM script execution engine (javax.script) - \"dns\" - resolve dns records - \"url\" - load values from urls, including from remote servers Applications using the interpolation defaults in the affected versions may be vulnerable to remote code execution or unintentional contact with remote servers if untrusted configuration values are used. Users are recommended to upgrade to Apache Commons Text 1.10.0, which disables the problematic interpolators by default.",
"id": "GHSA-599f-7c49-w659",
"modified": "2022-10-17T17:34:05Z",
"published": "2022-10-13T19:00:17Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2022-42889"
},
{
"type": "WEB",
"url": "https://arxiv.org/pdf/2306.05534"
},
{
"type": "PACKAGE",
"url": "https://github.com/apache/commons-text"
},
{
"type": "WEB",
"url": "https://lists.apache.org/thread/n2bd4vdsgkqh2tm14l1wyc3jyol7s1om"
},
{
"type": "WEB",
"url": "https://psirt.global.sonicwall.com/vuln-detail/SNWLID-2022-0022"
},
{
"type": "WEB",
"url": "https://security.gentoo.org/glsa/202301-05"
},
{
"type": "WEB",
"url": "https://security.netapp.com/advisory/ntap-20221020-0004"
},
{
"type": "ADVISORY",
"url": "https://securitylab.github.com/advisories/GHSL-2022-018_Apache_Commons_Text"
},
{
"type": "WEB",
"url": "http://packetstormsecurity.com/files/171003/OX-App-Suite-Cross-Site-Scripting-Server-Side-Request-Forgery.html"
},
{
"type": "WEB",
"url": "http://packetstormsecurity.com/files/176650/Apache-Commons-Text-1.9-Remote-Code-Execution.html"
},
{
"type": "WEB",
"url": "http://seclists.org/fulldisclosure/2023/Feb/3"
},
{
"type": "WEB",
"url": "http://www.openwall.com/lists/oss-security/2022/10/13/4"
},
{
"type": "WEB",
"url": "http://www.openwall.com/lists/oss-security/2022/10/18/1"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
],
"summary": "Arbitrary code execution in Apache Commons Text"
}
Mitigation
Strategy: Refactoring
Refactor your program so that you do not have to dynamically generate code.
Mitigation
- 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.
Mitigation MIT-5
Strategy: Input Validation
- 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.
- To reduce the likelihood of code injection, use stringent allowlists that limit which constructs are allowed. If you are dynamically constructing code that invokes a function, then verifying that the input is alphanumeric might be insufficient. An attacker might still be able to reference a dangerous function that you did not intend to allow, such as system(), exec(), or exit().
Mitigation
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.
Mitigation MIT-32
Strategy: Compilation or Build Hardening
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).
Mitigation MIT-32
Strategy: Environment Hardening
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).
Mitigation
For Python programs, it is frequently encouraged to use the ast.literal_eval() function instead of eval, since it is intentionally designed to avoid executing code. However, an adversary could still cause excessive memory or stack consumption via deeply nested structures [REF-1372], so the python documentation discourages use of ast.literal_eval() on untrusted data [REF-1373].
CAPEC-242: Code Injection
An adversary exploits a weakness in input validation on the target to inject new code into that which is currently executing. This differs from code inclusion in that code inclusion involves the addition or replacement of a reference to a code file, which is subsequently loaded by the target and used as part of the code of some application.
CAPEC-35: Leverage Executable Code in Non-Executable Files
An attack of this type exploits a system's trust in configuration and resource files. When the executable loads the resource (such as an image file or configuration file) the attacker has modified the file to either execute malicious code directly or manipulate the target process (e.g. application server) to execute based on the malicious configuration parameters. Since systems are increasingly interrelated mashing up resources from local and remote sources the possibility of this attack occurring is high.
CAPEC-77: Manipulating User-Controlled Variables
This attack targets user controlled variables (DEBUG=1, PHP Globals, and So Forth). An adversary can override variables leveraging user-supplied, untrusted query variables directly used on the application server without any data sanitization. In extreme cases, the adversary can change variables controlling the business logic of the application. For instance, in languages like PHP, a number of poorly set default configurations may allow the user to override variables.