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.
8358 vulnerabilities reference this CWE, most recent first.
GHSA-44PW-F9WR-W46W
Vulnerability from github – Published: 2022-05-02 03:45 – Updated: 2022-05-02 03:45Adobe Shockwave Player before 11.5.2.602 allows remote attackers to execute arbitrary code via crafted Shockwave content on a web site, related to an "invalid pointer vulnerability," a different issue than CVE-2009-3464. NOTE: some of these details are obtained from third party information.
{
"affected": [],
"aliases": [
"CVE-2009-3465"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2009-11-04T15:30:00Z",
"severity": "HIGH"
},
"details": "Adobe Shockwave Player before 11.5.2.602 allows remote attackers to execute arbitrary code via crafted Shockwave content on a web site, related to an \"invalid pointer vulnerability,\" a different issue than CVE-2009-3464. NOTE: some of these details are obtained from third party information.",
"id": "GHSA-44pw-f9wr-w46w",
"modified": "2022-05-02T03:45:28Z",
"published": "2022-05-02T03:45:28Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2009-3465"
},
{
"type": "WEB",
"url": "https://exchange.xforce.ibmcloud.com/vulnerabilities/54120"
},
{
"type": "WEB",
"url": "https://oval.cisecurity.org/repository/search/definition/oval%3Aorg.mitre.oval%3Adef%3A5722"
},
{
"type": "WEB",
"url": "http://securitytracker.com/id?1023123"
},
{
"type": "WEB",
"url": "http://www.adobe.com/support/security/bulletins/apsb09-16.html"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/bid/36905"
},
{
"type": "WEB",
"url": "http://www.vupen.com/english/advisories/2009/3134"
}
],
"schema_version": "1.4.0",
"severity": []
}
GHSA-44QV-X6F8-2JWM
Vulnerability from github – Published: 2022-12-22 12:30 – Updated: 2022-12-29 18:30In JetBrains IntelliJ IDEA before 2022.3.1 code Templates were vulnerable to SSTI attacks.
{
"affected": [],
"aliases": [
"CVE-2022-47896"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2022-12-22T11:15:00Z",
"severity": "HIGH"
},
"details": "In JetBrains IntelliJ IDEA before 2022.3.1 code Templates were vulnerable to SSTI attacks.",
"id": "GHSA-44qv-x6f8-2jwm",
"modified": "2022-12-29T18:30:24Z",
"published": "2022-12-22T12:30:16Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2022-47896"
},
{
"type": "WEB",
"url": "https://www.jetbrains.com/privacy-security/issues-fixed"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-44V6-JHGM-P3M4
Vulnerability from github – Published: 2026-04-29 21:21 – Updated: 2026-05-08 01:31Impact
An authenticated user with permission to create or modify workflows containing a Python Code Node could escape the sandbox and achieve arbitrary code execution on the task runner container.
- This issue only affects instances where the Python Task Runner is enabled.
Patches
The issue has been fixed in n8n versions 1.123.32, 2.17.4, and 2.18.1. 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 Python Code node by adding n8n-nodes-base.code to the NODES_EXCLUDE environment variable, or disable the Python Task Runner entirely.
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": "0"
},
{
"fixed": "1.123.32"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"package": {
"ecosystem": "npm",
"name": "n8n"
},
"ranges": [
{
"events": [
{
"introduced": "2.18.0"
},
{
"fixed": "2.18.1"
}
],
"type": "ECOSYSTEM"
}
]
},
{
"package": {
"ecosystem": "npm",
"name": "n8n"
},
"ranges": [
{
"events": [
{
"introduced": "2.17.0"
},
{
"fixed": "2.17.4"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-42234"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": true,
"github_reviewed_at": "2026-04-29T21:21:50Z",
"nvd_published_at": "2026-05-04T19:16:06Z",
"severity": "HIGH"
},
"details": "## Impact\nAn authenticated user with permission to create or modify workflows containing a Python Code Node could escape the sandbox and achieve arbitrary code execution on the task runner container.\n\n- This issue only affects instances where the Python Task Runner is enabled.\n\n## Patches\nThe issue has been fixed in n8n versions 1.123.32, 2.17.4, and 2.18.1. 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 Python Code node by adding `n8n-nodes-base.code` to the `NODES_EXCLUDE` environment variable, or disable the Python Task Runner entirely.\n\nThese workarounds do not fully remediate the risk and should only be used as short-term mitigation measures.",
"id": "GHSA-44v6-jhgm-p3m4",
"modified": "2026-05-08T01:31:22Z",
"published": "2026-04-29T21:21:50Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/n8n-io/n8n/security/advisories/GHSA-44v6-jhgm-p3m4"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-42234"
},
{
"type": "PACKAGE",
"url": "https://github.com/n8n-io/n8n"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H",
"type": "CVSS_V3"
},
{
"score": "CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:L/VA:N/SC:N/SI:N/SA:N",
"type": "CVSS_V4"
}
],
"summary": "n8n has a Python Task Runner Sandbox Escape Vulnerability"
}
GHSA-44VG-5WV2-H2HG
Vulnerability from github – Published: 2026-03-13 20:56 – Updated: 2026-06-08 19:47Impact
If the objects passed in as names to SimpleEval have modules or other disallowed / dangerous objects available as attrs.
Additionally, dangerous functions or modules could be accessed by passing them as callbacks to other safe functions to call.
Examples (found by @ByamB4):
Any module where non-underscore attribute chains reach os or sys: - os.path, pathlib, shutil, glob (direct .os / .sys attributes) - statistics (has .sys) - numpy (has .ctypeslib.os and .f2py.sys) - urllib.parse (has .warnings.sys)
Patches
The latest version 1.0.5 has this issue fixed.
Workarounds
Don't pass in objects or modules which have direct attributes to potentially dangerous items. Use a wrapper to wrap the potentially vulnerable items (See the ModuleWrapper in version 1.0.5)
{
"affected": [
{
"package": {
"ecosystem": "PyPI",
"name": "simpleeval"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "1.0.5"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-32640"
],
"database_specific": {
"cwe_ids": [
"CWE-915",
"CWE-94"
],
"github_reviewed": true,
"github_reviewed_at": "2026-03-13T20:56:26Z",
"nvd_published_at": "2026-03-16T14:19:40Z",
"severity": "HIGH"
},
"details": "### Impact\nIf the objects passed in as `names` to SimpleEval have modules or other disallowed / dangerous objects available as attrs.\nAdditionally, dangerous functions or modules could be accessed by passing them as callbacks to other safe functions to call.\n\nExamples (found by @ByamB4):\n\nAny module where non-underscore attribute chains reach os or sys:\n- os.path, pathlib, shutil, glob (direct .os / .sys attributes)\n- statistics (has .sys)\n- numpy (has .ctypeslib.os and .f2py.sys)\n- urllib.parse (has .warnings.sys)\n\n### Patches\nThe latest version 1.0.5 has this issue fixed.\n\n### Workarounds\nDon\u0027t pass in objects or modules which have direct attributes to potentially dangerous items.\nUse a wrapper to wrap the potentially vulnerable items (See the ModuleWrapper in version 1.0.5)",
"id": "GHSA-44vg-5wv2-h2hg",
"modified": "2026-06-08T19:47:08Z",
"published": "2026-03-13T20:56:26Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/danthedeckie/simpleeval/security/advisories/GHSA-44vg-5wv2-h2hg"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-32640"
},
{
"type": "PACKAGE",
"url": "https://github.com/danthedeckie/simpleeval"
},
{
"type": "WEB",
"url": "https://github.com/danthedeckie/simpleeval/releases/tag/1.0.5"
},
{
"type": "WEB",
"url": "https://github.com/pypa/advisory-database/tree/main/vulns/simpleeval/PYSEC-2026-132.yaml"
},
{
"type": "WEB",
"url": "https://lists.debian.org/debian-lts-announce/2026/04/msg00023.html"
}
],
"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"
},
{
"score": "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N",
"type": "CVSS_V4"
}
],
"summary": "SimpleEval: Objects (including modules) can leak dangerous modules through to direct access inside the sandbox"
}
GHSA-4522-GJ56-9PV6
Vulnerability from github – Published: 2022-05-24 17:11 – Updated: 2022-05-24 17:11An issue was discovered in ONAP SDC through Dublin. By accessing port 6000 of demo-sdc-sdc-fe pod, an unauthenticated attacker (who already has access to pod-to-pod communication) may execute arbitrary code inside that pod. All ONAP Operations Manager (OOM) setups are affected.
{
"affected": [],
"aliases": [
"CVE-2019-12116"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2020-03-18T19:15:00Z",
"severity": "HIGH"
},
"details": "An issue was discovered in ONAP SDC through Dublin. By accessing port 6000 of demo-sdc-sdc-fe pod, an unauthenticated attacker (who already has access to pod-to-pod communication) may execute arbitrary code inside that pod. All ONAP Operations Manager (OOM) setups are affected.",
"id": "GHSA-4522-gj56-9pv6",
"modified": "2022-05-24T17:11:46Z",
"published": "2022-05-24T17:11:46Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2019-12116"
},
{
"type": "WEB",
"url": "https://jira.onap.org/browse/OJSI-10"
}
],
"schema_version": "1.4.0",
"severity": []
}
GHSA-453Q-Q3MP-9CQ4
Vulnerability from github – Published: 2022-05-14 02:19 – Updated: 2025-10-22 00:31Samba since version 3.5.0 and before 4.6.4, 4.5.10 and 4.4.14 is vulnerable to remote code execution vulnerability, allowing a malicious client to upload a shared library to a writable share, and then cause the server to load and execute it.
{
"affected": [],
"aliases": [
"CVE-2017-7494"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2017-05-30T18:29:00Z",
"severity": "CRITICAL"
},
"details": "Samba since version 3.5.0 and before 4.6.4, 4.5.10 and 4.4.14 is vulnerable to remote code execution vulnerability, allowing a malicious client to upload a shared library to a writable share, and then cause the server to load and execute it.",
"id": "GHSA-453q-q3mp-9cq4",
"modified": "2025-10-22T00:31:22Z",
"published": "2022-05-14T02:19:45Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2017-7494"
},
{
"type": "WEB",
"url": "https://access.redhat.com/errata/RHSA-2017:1270"
},
{
"type": "WEB",
"url": "https://access.redhat.com/errata/RHSA-2017:1271"
},
{
"type": "WEB",
"url": "https://access.redhat.com/errata/RHSA-2017:1272"
},
{
"type": "WEB",
"url": "https://access.redhat.com/errata/RHSA-2017:1273"
},
{
"type": "WEB",
"url": "https://access.redhat.com/errata/RHSA-2017:1390"
},
{
"type": "WEB",
"url": "https://download.schneider-electric.com/files?p_enDocType=Technical+leaflet\u0026p_File_Name=SEVD-2018-095-01+Security+Notification+Umotion+V1.1.pdf\u0026p_Doc_Ref=SEVD-2018-095-01"
},
{
"type": "WEB",
"url": "https://h20566.www2.hpe.com/hpsc/doc/public/display?docLocale=en_US\u0026docId=emr_na-hpesbns03755en_us"
},
{
"type": "WEB",
"url": "https://h20566.www2.hpe.com/hpsc/doc/public/display?docLocale=en_US\u0026docId=emr_na-hpesbux03759en_us"
},
{
"type": "WEB",
"url": "https://security.gentoo.org/glsa/201805-07"
},
{
"type": "WEB",
"url": "https://security.netapp.com/advisory/ntap-20170524-0001"
},
{
"type": "WEB",
"url": "https://www.cisa.gov/known-exploited-vulnerabilities-catalog?field_cve=CVE-2017-7494"
},
{
"type": "WEB",
"url": "https://www.exploit-db.com/exploits/42060"
},
{
"type": "WEB",
"url": "https://www.exploit-db.com/exploits/42084"
},
{
"type": "WEB",
"url": "https://www.samba.org/samba/security/CVE-2017-7494.html"
},
{
"type": "WEB",
"url": "http://www.debian.org/security/2017/dsa-3860"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/bid/98636"
},
{
"type": "WEB",
"url": "http://www.securitytracker.com/id/1038552"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-4564-2F76-RV6P
Vulnerability from github – Published: 2022-05-02 03:16 – Updated: 2022-05-02 03:16Microsoft Office Publisher 2007 SP1 does not properly calculate object handler data for Publisher files, which allows remote attackers to execute arbitrary code via a crafted file in a legacy format that triggers memory corruption, aka "Pointer Dereference Vulnerability."
{
"affected": [],
"aliases": [
"CVE-2009-0566"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2009-07-15T15:30:00Z",
"severity": "HIGH"
},
"details": "Microsoft Office Publisher 2007 SP1 does not properly calculate object handler data for Publisher files, which allows remote attackers to execute arbitrary code via a crafted file in a legacy format that triggers memory corruption, aka \"Pointer Dereference Vulnerability.\"",
"id": "GHSA-4564-2f76-rv6p",
"modified": "2022-05-02T03:16:37Z",
"published": "2022-05-02T03:16:37Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2009-0566"
},
{
"type": "WEB",
"url": "https://docs.microsoft.com/en-us/security-updates/securitybulletins/2009/ms09-030"
},
{
"type": "WEB",
"url": "https://oval.cisecurity.org/repository/search/definition/oval%3Aorg.mitre.oval%3Adef%3A6285"
},
{
"type": "WEB",
"url": "http://osvdb.org/55838"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/bid/35599"
},
{
"type": "WEB",
"url": "http://www.securitytracker.com/id?1022546"
},
{
"type": "WEB",
"url": "http://www.us-cert.gov/cas/techalerts/TA09-195A.html"
},
{
"type": "WEB",
"url": "http://www.vupen.com/english/advisories/2009/1888"
}
],
"schema_version": "1.4.0",
"severity": []
}
GHSA-45C8-FF6W-R2C9
Vulnerability from github – Published: 2022-05-01 18:30 – Updated: 2022-05-01 18:30PHP remote file inclusion vulnerability in includes/archive/archive_topic.php in IntegraMOD Nederland 1.4.2 allows remote attackers to execute arbitrary PHP code via a URL in the phpbb_root_path parameter.
{
"affected": [],
"aliases": [
"CVE-2007-5140"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2007-09-28T21:17:00Z",
"severity": "MODERATE"
},
"details": "PHP remote file inclusion vulnerability in includes/archive/archive_topic.php in IntegraMOD Nederland 1.4.2 allows remote attackers to execute arbitrary PHP code via a URL in the phpbb_root_path parameter.",
"id": "GHSA-45c8-ff6w-r2c9",
"modified": "2022-05-01T18:30:35Z",
"published": "2022-05-01T18:30:35Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2007-5140"
},
{
"type": "WEB",
"url": "https://exchange.xforce.ibmcloud.com/vulnerabilities/36832"
},
{
"type": "WEB",
"url": "https://www.exploit-db.com/exploits/4463"
},
{
"type": "WEB",
"url": "http://secunia.com/advisories/26991"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/bid/25832"
},
{
"type": "WEB",
"url": "http://www.vupen.com/english/advisories/2007/3307"
}
],
"schema_version": "1.4.0",
"severity": []
}
GHSA-45FV-8PR3-CVF3
Vulnerability from github – Published: 2022-05-24 16:52 – Updated: 2024-04-04 01:28cPanel before 70.0.23 allows demo accounts to execute code via the Landing Page (SEC-405).
{
"affected": [],
"aliases": [
"CVE-2018-20931"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2019-08-01T16:15:00Z",
"severity": "MODERATE"
},
"details": "cPanel before 70.0.23 allows demo accounts to execute code via the Landing Page (SEC-405).",
"id": "GHSA-45fv-8pr3-cvf3",
"modified": "2024-04-04T01:28:31Z",
"published": "2022-05-24T16:52:09Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2018-20931"
},
{
"type": "WEB",
"url": "https://documentation.cpanel.net/display/CL/70+Change+Log"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.0/AV:N/AC:L/PR:L/UI:N/S:U/C:L/I:L/A:L",
"type": "CVSS_V3"
}
]
}
GHSA-45G3-MF2X-6MXC
Vulnerability from github – Published: 2022-05-01 06:39 – Updated: 2022-05-01 06:39Pantomime in Ecartis 1.0.0 snapshot 20050909 stores e-mail attachments in a publicly accessible directory, which may allow remote attackers to upload arbitrary files.
{
"affected": [],
"aliases": [
"CVE-2006-0332"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2006-01-21T00:03:00Z",
"severity": "MODERATE"
},
"details": "Pantomime in Ecartis 1.0.0 snapshot 20050909 stores e-mail attachments in a publicly accessible directory, which may allow remote attackers to upload arbitrary files.",
"id": "GHSA-45g3-mf2x-6mxc",
"modified": "2022-05-01T06:39:00Z",
"published": "2022-05-01T06:39:00Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2006-0332"
},
{
"type": "WEB",
"url": "https://exchange.xforce.ibmcloud.com/vulnerabilities/24220"
},
{
"type": "WEB",
"url": "http://marc.info/?l=listar-dev\u0026m=113732552708625\u0026w=2"
},
{
"type": "WEB",
"url": "http://marc.info/?l=listar-dev\u0026m=113770802408358\u0026w=2"
},
{
"type": "WEB",
"url": "http://secunia.com/advisories/18524"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/bid/16317"
},
{
"type": "WEB",
"url": "http://www.vupen.com/english/advisories/2006/0260"
}
],
"schema_version": "1.4.0",
"severity": []
}
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.