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.
8307 vulnerabilities reference this CWE, most recent first.
GHSA-VHWQ-33MX-JMX5
Vulnerability from github – Published: 2024-12-17 00:31 – Updated: 2024-12-17 18:33An HTML injection vulnerability in Sunbird DCIM dcTrack 9.1.2 allows attackers authenticated as administrators to inject arbitrary HTML code in an admin screen.
{
"affected": [],
"aliases": [
"CVE-2024-37773"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2024-12-16T22:15:05Z",
"severity": "MODERATE"
},
"details": "An HTML injection vulnerability in Sunbird DCIM dcTrack 9.1.2 allows attackers authenticated as administrators to inject arbitrary HTML code in an admin screen.",
"id": "GHSA-vhwq-33mx-jmx5",
"modified": "2024-12-17T18:33:47Z",
"published": "2024-12-17T00:31:17Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2024-37773"
},
{
"type": "WEB",
"url": "https://s3.us-east-1.amazonaws.com/dcTrack.Docs/dcTrack_9.2.0_GA/dcTrack_9.2.0_Release_Notes.pdf"
},
{
"type": "WEB",
"url": "http://dctrack.com"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:H/UI:R/S:C/C:L/I:L/A:N",
"type": "CVSS_V3"
}
]
}
GHSA-VJ4F-3P4C-M596
Vulnerability from github – Published: 2026-06-26 15:32 – Updated: 2026-06-26 15:32Contributor Remote Code Execution (RCE) in Blocksy Companion Pro <= 2.1.45 versions.
{
"affected": [],
"aliases": [
"CVE-2026-57315"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2026-06-26T15:16:48Z",
"severity": "HIGH"
},
"details": "Contributor Remote Code Execution (RCE) in Blocksy Companion Pro \u003c= 2.1.45 versions.",
"id": "GHSA-vj4f-3p4c-m596",
"modified": "2026-06-26T15:32:17Z",
"published": "2026-06-26T15:32:17Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-57315"
},
{
"type": "WEB",
"url": "https://patchstack.com/database/wordpress/plugin/blocksy-companion-pro/vulnerability/wordpress-blocksy-companion-pro-plugin-2-1-45-remote-code-execution-rce-vulnerability?_s_id=cve"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:C/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-VJ54-Q292-HVX8
Vulnerability from github – Published: 2022-05-01 06:52 – Updated: 2022-05-01 06:52PHP remote file inclusion vulnerability in functions.php in Circle R Monster Top List (MTL) 1.4 allows remote attackers to execute arbitrary PHP code via a URL in the root_path parameter. NOTE: It was later reported that 1.4.2 and earlier are affected.
{
"affected": [],
"aliases": [
"CVE-2006-1781"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2006-04-13T10:02:00Z",
"severity": "HIGH"
},
"details": "PHP remote file inclusion vulnerability in functions.php in Circle R Monster Top List (MTL) 1.4 allows remote attackers to execute arbitrary PHP code via a URL in the root_path parameter. NOTE: It was later reported that 1.4.2 and earlier are affected.",
"id": "GHSA-vj54-q292-hvx8",
"modified": "2022-05-01T06:52:47Z",
"published": "2022-05-01T06:52:47Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2006-1781"
},
{
"type": "WEB",
"url": "https://exchange.xforce.ibmcloud.com/vulnerabilities/25774"
},
{
"type": "WEB",
"url": "https://www.exploit-db.com/exploits/3530"
},
{
"type": "WEB",
"url": "http://pridels0.blogspot.com/2006/04/monstertoplist.html"
},
{
"type": "WEB",
"url": "http://secunia.com/advisories/19688"
},
{
"type": "WEB",
"url": "http://www.osvdb.org/24650"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/bid/17546"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/bid/23074"
},
{
"type": "WEB",
"url": "http://www.vupen.com/english/advisories/2006/1350"
}
],
"schema_version": "1.4.0",
"severity": []
}
GHSA-VJ54-QX98-6X64
Vulnerability from github – Published: 2022-05-02 03:25 – Updated: 2022-05-02 03:25PHP remote file inclusion vulnerability in indexk.php in WebPortal CMS 0.8-beta allows remote attackers to execute arbitrary PHP code via a URL in the lib_path parameter.
{
"affected": [],
"aliases": [
"CVE-2009-1444"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2009-04-27T19:30:00Z",
"severity": "HIGH"
},
"details": "PHP remote file inclusion vulnerability in indexk.php in WebPortal CMS 0.8-beta allows remote attackers to execute arbitrary PHP code via a URL in the lib_path parameter.",
"id": "GHSA-vj54-qx98-6x64",
"modified": "2022-05-02T03:25:14Z",
"published": "2022-05-02T03:25:14Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2009-1444"
},
{
"type": "WEB",
"url": "https://www.exploit-db.com/exploits/8516"
},
{
"type": "WEB",
"url": "http://osvdb.org/54121"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/bid/34687"
}
],
"schema_version": "1.4.0",
"severity": []
}
GHSA-VJ8F-R84J-PCVR
Vulnerability from github – Published: 2024-11-18 21:30 – Updated: 2024-11-19 18:30Insecure Permissions vulnerability in Micro-star International MSI Center Pro 2.1.37.0 allows a local attacker to execute arbitrary code via the Device_DeviceID.dat.bak file within the C:\ProgramData\MSI\One Dragon Center\Data folder
{
"affected": [],
"aliases": [
"CVE-2024-50804"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2024-11-18T21:15:06Z",
"severity": "HIGH"
},
"details": "Insecure Permissions vulnerability in Micro-star International MSI Center Pro 2.1.37.0 allows a local attacker to execute arbitrary code via the Device_DeviceID.dat.bak file within the C:\\ProgramData\\MSI\\One Dragon Center\\Data folder",
"id": "GHSA-vj8f-r84j-pcvr",
"modified": "2024-11-19T18:30:59Z",
"published": "2024-11-18T21:30:47Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2024-50804"
},
{
"type": "WEB",
"url": "https://g3tsyst3m.github.io/cve/msi/Arbitrary-Write-Privilege-Escalation-CVE-2024-50804"
}
],
"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-VJMV-F9R4-765G
Vulnerability from github – Published: 2022-05-24 17:28 – Updated: 2024-01-01 00:30A remote code execution vulnerability exists in Visual Studio when it improperly handles objects in memory, aka 'Visual Studio Remote Code Execution Vulnerability'. This CVE ID is unique from CVE-2020-16856.
{
"affected": [],
"aliases": [
"CVE-2020-16874"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2020-09-11T17:15:00Z",
"severity": "HIGH"
},
"details": "A remote code execution vulnerability exists in Visual Studio when it improperly handles objects in memory, aka \u0027Visual Studio Remote Code Execution Vulnerability\u0027. This CVE ID is unique from CVE-2020-16856.",
"id": "GHSA-vjmv-f9r4-765g",
"modified": "2024-01-01T00:30:40Z",
"published": "2022-05-24T17:28:07Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2020-16874"
},
{
"type": "WEB",
"url": "https://portal.msrc.microsoft.com/en-US/security-guidance/advisory/CVE-2020-16874"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-VJPH-W72M-276X
Vulnerability from github – Published: 2025-02-07 21:31 – Updated: 2025-03-13 15:32An error related to the 2-factor authorization (2FA) on the RISC Platform prior to the saas-2021-12-29 release can potentially be exploited to bypass the 2FA. The vulnerability requires that the 2FA setup hasn’t been completed.
{
"affected": [],
"aliases": [
"CVE-2021-41527"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2025-02-07T20:15:32Z",
"severity": "LOW"
},
"details": "An error related to the 2-factor authorization (2FA) on the RISC Platform prior to the\u00a0saas-2021-12-29 release\u00a0can potentially be exploited to bypass the 2FA. The vulnerability requires that the 2FA setup hasn\u2019t been completed.",
"id": "GHSA-vjph-w72m-276x",
"modified": "2025-03-13T15:32:46Z",
"published": "2025-02-07T21:31:02Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2021-41527"
},
{
"type": "WEB",
"url": "https://community.flexera.com/s/feed/0D5PL00000Nwgg30AB"
},
{
"type": "WEB",
"url": "https://medium.com/@amroot/cve-2021-41527-flexera-multi-factor-authentication-mfa-bypass-cb9effc3af98"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X",
"type": "CVSS_V4"
}
]
}
GHSA-VJW2-5FJM-HHR4
Vulnerability from github – Published: 2023-08-11 06:30 – Updated: 2024-04-04 06:52Improper Authentication vulnerability in Genians Genian NAC V4.0, Genians Genian NAC V5.0, Genians Genian NAC Suite V5.0, Genians Genian ZTNA allows Functionality Misuse.This issue affects Genian NAC V4.0: from V4.0.0 through V4.0.155; Genian NAC V5.0: from V5.0.0 through V5.0.42 (Revision 117460); Genian NAC Suite V5.0: from V5.0.0 through V5.0.54; Genian ZTNA: from V6.0.0 through V6.0.15.
{
"affected": [],
"aliases": [
"CVE-2023-40253"
],
"database_specific": {
"cwe_ids": [
"CWE-287",
"CWE-78",
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2023-08-11T06:15:10Z",
"severity": "CRITICAL"
},
"details": "Improper Authentication vulnerability in Genians Genian NAC V4.0, Genians Genian NAC V5.0, Genians Genian NAC Suite V5.0, Genians Genian ZTNA allows Functionality Misuse.This issue affects Genian NAC V4.0: from V4.0.0 through V4.0.155; Genian NAC V5.0: from V5.0.0 through V5.0.42 (Revision 117460); Genian NAC Suite V5.0: from V5.0.0 through V5.0.54; Genian ZTNA: from V6.0.0 through V6.0.15.\n\n",
"id": "GHSA-vjw2-5fjm-hhr4",
"modified": "2024-04-04T06:52:18Z",
"published": "2023-08-11T06:30:36Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2023-40253"
},
{
"type": "WEB",
"url": "https://docs.genians.com/nac/5.0/release/ko/advisories/GN-SA-2023-001.html"
},
{
"type": "WEB",
"url": "https://www.genians.co.kr/notice/2023"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:U/C:N/I:H/A:N",
"type": "CVSS_V3"
}
]
}
GHSA-VJW9-G6X3-5GPJ
Vulnerability from github – Published: 2022-05-01 07:44 – Updated: 2022-05-01 07:44PHP remote file inclusion vulnerability in includes/functions_mod_user.php in phpBB Insert User 0.1.2 and earlier allows remote attackers to execute arbitrary PHP code via a URL in the phpbb_root_path parameter.
{
"affected": [],
"aliases": [
"CVE-2006-7100"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2007-03-03T21:19:00Z",
"severity": "MODERATE"
},
"details": "PHP remote file inclusion vulnerability in includes/functions_mod_user.php in phpBB Insert User 0.1.2 and earlier allows remote attackers to execute arbitrary PHP code via a URL in the phpbb_root_path parameter.",
"id": "GHSA-vjw9-g6x3-5gpj",
"modified": "2022-05-01T07:44:45Z",
"published": "2022-05-01T07:44:45Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2006-7100"
},
{
"type": "WEB",
"url": "https://www.exploit-db.com/exploits/2525"
},
{
"type": "WEB",
"url": "http://securityreason.com/securityalert/2331"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/archive/1/448542/100/0/threaded"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/bid/20493"
}
],
"schema_version": "1.4.0",
"severity": []
}
GHSA-VM2F-3GPJ-98M4
Vulnerability from github – Published: 2022-05-13 01:18 – Updated: 2022-05-13 01:18Dell EMC iDRAC7/iDRAC8, versions prior to 2.52.52.52, contain CGI injection vulnerability which could be used to execute remote code. A remote unauthenticated attacker may potentially be able to use CGI variables to execute remote code.
{
"affected": [],
"aliases": [
"CVE-2018-1207"
],
"database_specific": {
"cwe_ids": [
"CWE-94"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2018-03-23T14:29:00Z",
"severity": "CRITICAL"
},
"details": "Dell EMC iDRAC7/iDRAC8, versions prior to 2.52.52.52, contain CGI injection vulnerability which could be used to execute remote code. A remote unauthenticated attacker may potentially be able to use CGI variables to execute remote code.",
"id": "GHSA-vm2f-3gpj-98m4",
"modified": "2022-05-13T01:18:59Z",
"published": "2022-05-13T01:18:59Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2018-1207"
},
{
"type": "WEB",
"url": "https://twitter.com/nicowaisman/status/977279766792466432"
},
{
"type": "WEB",
"url": "http://en.community.dell.com/techcenter/extras/m/white_papers/20485410"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/bid/103694"
}
],
"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"
}
]
}
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.