CWE-94 对生成代码的控制不恰当(代码注入) 类弱点 2110 条 CVE 漏洞汇总,含 AI 中文分析。
CWE-94 指代码注入漏洞,属于输入验证缺陷。攻击者通过向程序提供恶意构造的外部输入,利用未正确过滤的特殊字符或代码片段,篡改预期代码逻辑或注入可执行指令,从而劫持系统控制权。开发者应避免直接拼接用户输入,采用白名单验证机制,并使用参数化查询或沙箱环境隔离执行上下文,确保输入数据的合法性与安全性,从根本上阻断恶意代码的注入路径。
$MessageFile = "messages.out"; if ($_GET["action"] == "NewMessage") { $name = $_GET["name"]; $message = $_GET["message"]; $handle = fopen($MessageFile, "a+"); fwrite($handle, "<b>$name</b> says '$message'<hr>\n"); fclose($handle); echo "Message Saved!<p>\n"; } else if ($_GET["action"] == "ViewMessages") { include($MessageFile); }
name=h4x0r message=%3C?php%20system(%22/bin/ls%20-l%22);?%3E
use CGI qw(:standard); sub config_file_add_key { my ($fname, $key, $arg) = @_; # code to add a field/key to a file goes here } sub config_file_set_key { my ($fname, $key, $arg) = @_; # code to set key to a particular file goes here } sub config_file_delete_key { my ($fname, $key, $arg) = @_; # code to delete key from a particular file goes here } sub handleConfigAction { my ($fname, $action) = @_; my $key = param('key'); my $val = param('val'); # this is super-efficient code, especially if you have to invoke # any one of dozens of different functions! my $code = "config_file_$action_key(\$fnam
add_key(",","); system("/bin/ls");
| CVE ID | 标题 | CVSS | 风险等级 | Published |
|---|---|---|---|---|
| CVE-2022-27837 | Samsung Accessibility安全漏洞 — Accessibility | 4.4 | Medium | 2022-04-11 |
| CVE-2022-24780 | Combodo iTop 代码注入漏洞 — iTop | 8.8 | High | 2022-04-05 |
| CVE-2022-1159 | Rockwell Automation Studio 5000 Logix Designer 代码注入漏洞 — Studio 5000 Logix Designer | 7.7 | High | 2022-04-01 |
| CVE-2022-22965 | Spring Framework 代码注入漏洞 — Spring Framework | 9.8 | - | 2022-04-01 |
| CVE-2022-22963 | Spring Framework 代码注入漏洞 — Spring Cloud Function | 9.8 | - | 2022-04-01 |
| CVE-2020-25197 | GE Reason RT430 Clock 代码注入漏洞 — Reason RT43X Clocks | 9.8 | Critical | 2022-03-18 |
| CVE-2022-0811 | cri-o 代码注入漏洞 — CRI-O | 8.8 | - | 2022-03-16 |
| CVE-2021-25003 | WordPress plugin WPCargo Track & Trace 代码问题漏洞 — WPCargo Track & Trace | 9.8 | - | 2022-03-14 |
| CVE-2022-0921 | Microweber 代码问题漏洞 — microweber/microweber | 7.2 | - | 2022-03-11 |
| CVE-2022-24734 | MyBB 代码注入漏洞 — mybb | 7.2 | High | 2022-03-09 |
| CVE-2022-24915 | IPCOMM ipDIO 安全漏洞 — IPCOMM ipDIO | 8.0 | High | 2022-03-09 |
| CVE-2022-22985 | IPCOMM ipDIO 安全漏洞 — IPCOMM ipDIO | 8.8 | High | 2022-03-09 |
| CVE-2022-0845 | pytorch-lightning 代码注入漏洞 — pytorchlightning/pytorch-lightning | 8.8 | - | 2022-03-05 |
| CVE-2022-22947 | VMware Spring Cloud Gateway 代码注入漏洞 — Spring Cloud Gateway | 10.0 | - | 2022-03-03 |
| CVE-2022-0819 | Dolibarr 安全漏洞 — dolibarr/dolibarr | 8.1 | - | 2022-03-02 |
| CVE-2022-23642 | Sourcegraph 代码注入漏洞 — sourcegraph | 8.8 | High | 2022-02-18 |
| CVE-2022-24663 | WordPress plugin 代码注入漏洞 — PHP Everywhere | 9.9 | Critical | 2022-02-16 |
| CVE-2022-24665 | WordPress plugin代码注入漏洞 — PHP Everywhere | 9.9 | Critical | 2022-02-16 |
| CVE-2022-24664 | WordPress plugin代码注入漏洞 — PHP Everywhere | 9.9 | Critical | 2022-02-16 |
| CVE-2022-23434 | Samsung Bixby Vision 代码注入漏洞 — Bixby Vision | 4.4 | Medium | 2022-02-11 |
| CVE-2022-23426 | Samsung DeX Home 代码注入漏洞 — Samsung Mobile Devices | 4.4 | Medium | 2022-02-11 |
| CVE-2021-44521 | Apache Cassandra 代码注入漏洞 — Apache Cassandra | 9.1 | - | 2022-02-11 |
| CVE-2022-23631 | Superjson 代码注入漏洞 — superjson | 9.1 | Critical | 2022-02-09 |
| CVE-2022-21686 | Prestashop 代码注入漏洞 — PrestaShop | 9.0 | Critical | 2022-01-26 |
| CVE-2022-23008 | F5 Nginx 跨站脚本漏洞 — NGINX Controller API Management | 7.1 | - | 2022-01-25 |
| CVE-2021-45029 | Apache ShenYu 代码注入漏洞 — Apache ShenYu (incubating) | 9.8 | - | 2022-01-25 |
| CVE-2021-23154 | Lens 操作系统命令注入漏洞 — Lens | 6.3 | Medium | 2022-01-10 |
| CVE-2022-22286 | Samsung Bixby Routines App 代码注入漏洞 — Bixby Routines | 4.4 | Medium | 2022-01-07 |
| CVE-2022-22285 | Samsung Reminder App 代码注入漏洞 — Reminder | 4.4 | Medium | 2022-01-07 |
| CVE-2022-22270 | Samsung SMR 安全漏洞 — Samsung Mobile Devices | 4.4 | Medium | 2022-01-07 |
CWE-94(对生成代码的控制不恰当(代码注入)) 是常见的弱点类别,本平台收录该类弱点关联的 2110 条 CVE 漏洞。