CWE-78
AllowedImproper Neutralization of Special Elements used in an OS Command ('OS Command Injection')
Abstraction: Base · Status: Stable
The product constructs all or part of an OS command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended OS command when it is sent to a downstream component.
8242 vulnerabilities reference this CWE, most recent first.
GHSA-XW2W-JC5R-G6R7
Vulnerability from github – Published: 2025-05-21 18:33 – Updated: 2025-11-03 21:33Several OS command injection vulnerabilities exist in the device firmware in the /var/salia/mqtt.php script. By publishing a specially crafted message to a certain MQTT topic arbitrary OS commands can be executed with root permissions.
{
"affected": [],
"aliases": [
"CVE-2025-27804"
],
"database_specific": {
"cwe_ids": [
"CWE-78"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2025-05-21T12:16:21Z",
"severity": "MODERATE"
},
"details": "Several OS command injection vulnerabilities exist in the device firmware in the /var/salia/mqtt.php script. By publishing a specially crafted message to a certain MQTT topic arbitrary OS commands can be executed with root permissions.",
"id": "GHSA-xw2w-jc5r-g6r7",
"modified": "2025-11-03T21:33:57Z",
"published": "2025-05-21T18:33:29Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2025-27804"
},
{
"type": "WEB",
"url": "https://r.sec-consult.com/echarge"
},
{
"type": "WEB",
"url": "http://seclists.org/fulldisclosure/2025/May/23"
}
],
"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:N",
"type": "CVSS_V3"
}
]
}
GHSA-XW67-CG5F-4M2R
Vulnerability from github – Published: 2026-05-15 18:32 – Updated: 2026-06-09 10:27Summary
Type: Classic shell-metacharacter injection. The YPTSocket notification branch in plugin/Live/on_publish.php builds an execAsync() command line by string concatenation, single-quoting each argument but never calling escapeshellarg(). A ' in any of the three interpolated values ($users_id, $m3u8, $obj->liveTransmitionHistory_id) closes the quoted token and lets the attacker append arbitrary commands.
File: plugin/Live/on_publish.php, line 267.
Root cause: the developer wrapped each variable in literal single quotes ('$users_id', '$m3u8', '$obj->liveTransmitionHistory_id') believing this provides shell-quoting. PHP single-quoted-into-shell is not safe quoting; it is just two literal quote characters that the shell pairs greedily. Any embedded ' closes the outer string and resumes interpretation in the shell. The rest of the AVideo codebase already calls escapeshellarg() (137 call sites across the project) for ffmpeg invocations, so the safe primitive is well-known to the project; it was simply omitted from this branch. The endpoint is web-reachable (no .htaccess rule restricts on_publish.php, no REMOTE_ADDR check), so the trigger is a direct HTTP POST without going through nginx-rtmp.
Affected Code
File: plugin/Live/on_publish.php, lines 256-271.
if (AVideoPlugin::isEnabledByName('YPTSocket')) {
$array = setLiveKey($lth->getKey(), $lth->getLive_servers_id());
@ob_clean();
_ob_start();
$lth = new LiveTransmitionHistory($obj->liveTransmitionHistory_id);
$m3u8 = Live::getM3U8File($lth->getKey(), false, true); // value-carrying URL: contains the stream key verbatim
$users_id = $obj->row['users_id'];
$liveTransmitionHistory_id = $obj->liveTransmitionHistory_id;
if (strtoupper(substr(PHP_OS, 0, 3)) === 'WIN') {
include "{$global['systemRootPath']}plugin/Live/on_publish_socket_notification.php";
} else {
$command = get_php(). " {$global['systemRootPath']}plugin/Live/on_publish_socket_notification.php '$users_id' '$m3u8' '{$obj->liveTransmitionHistory_id}'"; // <-- BUG: literal quotes, no escapeshellarg
$pid = execAsync($command); // sink: shell exec
}
}
Live::getM3U8File($key, false, true) (Live.php:1337-1350 -> Live.php:4845-4889) returns "{$playerServer}{$uuid}.m3u8" (or "{$playerServer}{$uuid}/index.m3u8") where $uuid = $this->getKeyWithIndex(...) is the stream key string read straight out of the live_transmitions table. There is no character normalisation between database read and command construction.
Why it's wrong: '$m3u8' is not shell quoting. PHP interpolates $m3u8 into the string between two literal ' characters. The shell then tokenises the result. If $m3u8 contains ' itself, the shell sees '…' followed by <attacker bytes> followed by another ', which forms two adjacent quoted strings concatenated with whatever the attacker put between them. Embedded ;, backticks, $(), &&, |, or \n then run as shell commands. The fix is escapeshellarg(), which AVideo already uses 137 times in ffmpeg invocations (e.g. getVideos.php:1069, videos.json.php, aVideoEncoder.json.php); this branch simply forgot it.
Exploit Chain
- Attacker authenticates and arranges for one of the command variables to contain
'. Under the current code the readily available primitive is acanStreamuser supplying a stream key via the persistence path (saveLive.php's$_REQUEST['key']is written verbatim tolive_transmitions.key). State: a row exists withkey = "evilkey';id>/tmp/pwn;#". - Attacker POSTs directly to
https://target/plugin/Live/on_publish.php(the file is web-served, no IP restriction) with body:name=evilkey';id>/tmp/pwn;# p=<md5(attacker_password)> tcurl=rtmp://target/live addr=1.2.3.4on_publish.php:117runspreg_replace("/[&=]/", '', $_POST['name'])— only&/=are stripped, so';id>/tmp/pwn;#survives. Lines 143-163 confirm$_GET['p'] === $user->getPassword()(the attacker is themself, knows their own MD5), persist aLiveTransmitionHistoryrow with the poisoned key, and set$obj->error = false. State: authorisation gate passed. - Line 261 calls
Live::getM3U8File($lth->getKey(), false, true), returning"https://server/live/evilkey';id>/tmp/pwn;#.m3u8". State:$m3u8carries the injection payload. - Line 267 builds the command string by concatenation:
php /var/www/AVideo/plugin/Live/on_publish_socket_notification.php '7' 'https://server/live/evilkey';id>/tmp/pwn;#.m3u8' '42'Shell tokenisation sees:php,…/on_publish_socket_notification.php,'7','https://server/live/evilkey'(the attacker's'closed the second quote), then operator;, then command-2id>/tmp/pwn, then;, then#.m3u8' '42'(everything after#is a comment). State: the shell has parsed two real commands. - Line 269
execAsync($command)spawns the shell, which runs the secondary commandid>/tmp/pwnas the AVideo PHP-FPM/Apache user. State: arbitrary OS command execution with the privileges of the web-server runtime user. - Final state: the attacker reads
/tmp/pwn, swaps the payload for a reverse shell, exfiltratesvideos/configuration.php(database password and root URL), drops a webshell into the upload tree, or pivots to other plugin credentials (PayPal/Stripe API keys, AWS keys for the CDN plugin, OpenAI key for the AI plugin).
Security Impact
Severity: sec-high. Pre-auth-friendly remote code execution: the only prerequisite is that the attacker can place a ' into one of the three command-line variables, which on a streaming platform means a single low-privilege account.
Attacker capability: with one canStream account and two HTTP requests, the attacker executes arbitrary shell commands as the AVideo runtime user. From there: read database credentials, exfiltrate user data, write a webshell into a publicly-served path, pivot to plugin credentials, persist via cron, or escalate via any local sudoers entries.
Preconditions: AVideo deployment with Live and YPTSocket plugins enabled (the standard live-streaming bundle); attacker can reach /plugin/Live/on_publish.php over the network; a value containing ' is reachable into users_id, m3u8, or liveTransmitionHistory_id (the current code lets canStream users supply such a value via the stream-key persistence path).
Differential: source-inspection-verified end-to-end. The shell-tokenising behaviour of '…'…'…' is reproducible offline:
$ s="php /a/b.php '7' 'https://s/live/evilkey';id>/tmp/pwn;#.m3u8' '42'"
$ rm -f /tmp/pwn; bash -c "$s" 2>/dev/null; ls -l /tmp/pwn
-rw-r--r-- 1 user user N <date> /tmp/pwn # injected `id` ran, output captured
The patched build (with the suggested escapeshellarg() fix below applied) constructs php /a/b.php '7' 'https://s/live/evilkey'\''id>/tmp/pwn;#.m3u8' '42', which the shell parses as a single argument containing the literal characters; the second command never runs.
Suggested Fix
Use escapeshellarg() on every variable interpolated into the command string. This matches established project conventions (137 other call sites for ffmpeg invocations).
--- a/plugin/Live/on_publish.php
+++ b/plugin/Live/on_publish.php
@@ -264,7 +264,11 @@
if (strtoupper(substr(PHP_OS, 0, 3)) === 'WIN') {
include "{$global['systemRootPath']}plugin/Live/on_publish_socket_notification.php";
} else {
- $command = get_php(). " {$global['systemRootPath']}plugin/Live/on_publish_socket_notification.php '$users_id' '$m3u8' '{$obj->liveTransmitionHistory_id}'";
+ $command = get_php()
+ . ' ' . escapeshellarg($global['systemRootPath'] . 'plugin/Live/on_publish_socket_notification.php')
+ . ' ' . escapeshellarg((string) $users_id)
+ . ' ' . escapeshellarg((string) $m3u8)
+ . ' ' . escapeshellarg((string) $obj->liveTransmitionHistory_id);
_error_log("NGINX Live::on_publish YPTSocket start ($command)");
$pid = execAsync($command);
}
Defence-in-depth: on_publish.php is the nginx-rtmp webhook and should not be reachable from the public Internet. Add an .htaccess/nginx location rule restricting the file to 127.0.0.1 and any configured RTMP server IPs. That blocks the trigger path independently of the sanitisation work.
{
"affected": [
{
"package": {
"ecosystem": "Packagist",
"name": "WWBN/AVideo"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"last_affected": "29.0"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-45578"
],
"database_specific": {
"cwe_ids": [
"CWE-78"
],
"github_reviewed": true,
"github_reviewed_at": "2026-05-15T18:32:36Z",
"nvd_published_at": "2026-05-29T14:16:30Z",
"severity": "HIGH"
},
"details": "## Summary\n\n**Type:** Classic shell-metacharacter injection. The YPTSocket notification branch in `plugin/Live/on_publish.php` builds an `execAsync()` command line by string concatenation, single-quoting each argument but never calling `escapeshellarg()`. A `\u0027` in any of the three interpolated values (`$users_id`, `$m3u8`, `$obj-\u003eliveTransmitionHistory_id`) closes the quoted token and lets the attacker append arbitrary commands.\n**File:** `plugin/Live/on_publish.php`, line 267.\n**Root cause:** the developer wrapped each variable in literal single quotes (`\u0027$users_id\u0027`, `\u0027$m3u8\u0027`, `\u0027$obj-\u003eliveTransmitionHistory_id\u0027`) believing this provides shell-quoting. PHP single-quoted-into-shell is not safe quoting; it is just two literal quote characters that the shell pairs greedily. Any embedded `\u0027` closes the outer string and resumes interpretation in the shell. The rest of the AVideo codebase already calls `escapeshellarg()` (137 call sites across the project) for ffmpeg invocations, so the safe primitive is well-known to the project; it was simply omitted from this branch. The endpoint is web-reachable (no `.htaccess` rule restricts `on_publish.php`, no `REMOTE_ADDR` check), so the trigger is a direct HTTP POST without going through nginx-rtmp.\n\n## Affected Code\n\n**File:** `plugin/Live/on_publish.php`, lines 256-271.\n\n```php\nif (AVideoPlugin::isEnabledByName(\u0027YPTSocket\u0027)) {\n $array = setLiveKey($lth-\u003egetKey(), $lth-\u003egetLive_servers_id());\n @ob_clean();\n _ob_start();\n $lth = new LiveTransmitionHistory($obj-\u003eliveTransmitionHistory_id);\n $m3u8 = Live::getM3U8File($lth-\u003egetKey(), false, true); // value-carrying URL: contains the stream key verbatim\n $users_id = $obj-\u003erow[\u0027users_id\u0027];\n $liveTransmitionHistory_id = $obj-\u003eliveTransmitionHistory_id;\n if (strtoupper(substr(PHP_OS, 0, 3)) === \u0027WIN\u0027) {\n include \"{$global[\u0027systemRootPath\u0027]}plugin/Live/on_publish_socket_notification.php\";\n } else {\n $command = get_php(). \" {$global[\u0027systemRootPath\u0027]}plugin/Live/on_publish_socket_notification.php \u0027$users_id\u0027 \u0027$m3u8\u0027 \u0027{$obj-\u003eliveTransmitionHistory_id}\u0027\"; // \u003c-- BUG: literal quotes, no escapeshellarg\n $pid = execAsync($command); // sink: shell exec\n }\n}\n```\n\n`Live::getM3U8File($key, false, true)` (`Live.php:1337-1350` -\u003e `Live.php:4845-4889`) returns `\"{$playerServer}{$uuid}.m3u8\"` (or `\"{$playerServer}{$uuid}/index.m3u8\"`) where `$uuid = $this-\u003egetKeyWithIndex(...)` is the stream key string read straight out of the `live_transmitions` table. There is no character normalisation between database read and command construction.\n\n**Why it\u0027s wrong:** `\u0027$m3u8\u0027` is not shell quoting. PHP interpolates `$m3u8` into the string between two literal `\u0027` characters. The shell then tokenises the result. If `$m3u8` contains `\u0027` itself, the shell sees `\u0027\u2026\u0027` followed by `\u003cattacker bytes\u003e` followed by another `\u0027`, which forms two adjacent quoted strings concatenated with whatever the attacker put between them. Embedded `;`, backticks, `$()`, `\u0026\u0026`, `|`, or `\\n` then run as shell commands. The fix is `escapeshellarg()`, which AVideo already uses 137 times in ffmpeg invocations (e.g. `getVideos.php:1069`, `videos.json.php`, `aVideoEncoder.json.php`); this branch simply forgot it.\n\n## Exploit Chain\n\n1. Attacker authenticates and arranges for one of the command variables to contain `\u0027`. Under the current code the readily available primitive is a `canStream` user supplying a stream key via the persistence path (`saveLive.php`\u0027s `$_REQUEST[\u0027key\u0027]` is written verbatim to `live_transmitions.key`). State: a row exists with `key = \"evilkey\u0027;id\u003e/tmp/pwn;#\"`.\n2. Attacker POSTs directly to `https://target/plugin/Live/on_publish.php` (the file is web-served, no IP restriction) with body:\n ```\n name=evilkey\u0027;id\u003e/tmp/pwn;#\n p=\u003cmd5(attacker_password)\u003e\n tcurl=rtmp://target/live\n addr=1.2.3.4\n ```\n `on_publish.php:117` runs `preg_replace(\"/[\u0026=]/\", \u0027\u0027, $_POST[\u0027name\u0027])` \u2014 only `\u0026`/`=` are stripped, so `\u0027;id\u003e/tmp/pwn;#` survives. Lines 143-163 confirm `$_GET[\u0027p\u0027] === $user-\u003egetPassword()` (the attacker is themself, knows their own MD5), persist a `LiveTransmitionHistory` row with the poisoned key, and set `$obj-\u003eerror = false`. State: authorisation gate passed.\n3. Line 261 calls `Live::getM3U8File($lth-\u003egetKey(), false, true)`, returning `\"https://server/live/evilkey\u0027;id\u003e/tmp/pwn;#.m3u8\"`. State: `$m3u8` carries the injection payload.\n4. Line 267 builds the command string by concatenation:\n ```\n php /var/www/AVideo/plugin/Live/on_publish_socket_notification.php \u00277\u0027 \u0027https://server/live/evilkey\u0027;id\u003e/tmp/pwn;#.m3u8\u0027 \u002742\u0027\n ```\n Shell tokenisation sees: `php`, `\u2026/on_publish_socket_notification.php`, `\u00277\u0027`, `\u0027https://server/live/evilkey\u0027` (the attacker\u0027s `\u0027` closed the second quote), then operator `;`, then command-2 `id\u003e/tmp/pwn`, then `;`, then `#.m3u8\u0027 \u002742\u0027` (everything after `#` is a comment). State: the shell has parsed two real commands.\n5. Line 269 `execAsync($command)` spawns the shell, which runs the secondary command `id\u003e/tmp/pwn` as the AVideo PHP-FPM/Apache user. State: arbitrary OS command execution with the privileges of the web-server runtime user.\n6. Final state: the attacker reads `/tmp/pwn`, swaps the payload for a reverse shell, exfiltrates `videos/configuration.php` (database password and root URL), drops a webshell into the upload tree, or pivots to other plugin credentials (PayPal/Stripe API keys, AWS keys for the CDN plugin, OpenAI key for the AI plugin).\n\n## Security Impact\n\n**Severity:** sec-high. Pre-auth-friendly remote code execution: the only prerequisite is that the attacker can place a `\u0027` into one of the three command-line variables, which on a streaming platform means a single low-privilege account.\n**Attacker capability:** with one `canStream` account and two HTTP requests, the attacker executes arbitrary shell commands as the AVideo runtime user. From there: read database credentials, exfiltrate user data, write a webshell into a publicly-served path, pivot to plugin credentials, persist via cron, or escalate via any local sudoers entries.\n**Preconditions:** AVideo deployment with `Live` and `YPTSocket` plugins enabled (the standard live-streaming bundle); attacker can reach `/plugin/Live/on_publish.php` over the network; a value containing `\u0027` is reachable into `users_id`, `m3u8`, or `liveTransmitionHistory_id` (the current code lets `canStream` users supply such a value via the stream-key persistence path).\n**Differential:** source-inspection-verified end-to-end. The shell-tokenising behaviour of `\u0027\u2026\u0027\u2026\u0027\u2026\u0027` is reproducible offline:\n\n```sh\n$ s=\"php /a/b.php \u00277\u0027 \u0027https://s/live/evilkey\u0027;id\u003e/tmp/pwn;#.m3u8\u0027 \u002742\u0027\"\n$ rm -f /tmp/pwn; bash -c \"$s\" 2\u003e/dev/null; ls -l /tmp/pwn\n-rw-r--r-- 1 user user N \u003cdate\u003e /tmp/pwn # injected `id` ran, output captured\n```\n\nThe patched build (with the suggested `escapeshellarg()` fix below applied) constructs `php /a/b.php \u00277\u0027 \u0027https://s/live/evilkey\u0027\\\u0027\u0027id\u003e/tmp/pwn;#.m3u8\u0027 \u002742\u0027`, which the shell parses as a single argument containing the literal characters; the second command never runs.\n\n## Suggested Fix\n\nUse `escapeshellarg()` on every variable interpolated into the command string. This matches established project conventions (137 other call sites for ffmpeg invocations).\n\n```diff\n--- a/plugin/Live/on_publish.php\n+++ b/plugin/Live/on_publish.php\n@@ -264,7 +264,11 @@\n if (strtoupper(substr(PHP_OS, 0, 3)) === \u0027WIN\u0027) {\n include \"{$global[\u0027systemRootPath\u0027]}plugin/Live/on_publish_socket_notification.php\";\n } else {\n- $command = get_php(). \" {$global[\u0027systemRootPath\u0027]}plugin/Live/on_publish_socket_notification.php \u0027$users_id\u0027 \u0027$m3u8\u0027 \u0027{$obj-\u003eliveTransmitionHistory_id}\u0027\";\n+ $command = get_php()\n+ . \u0027 \u0027 . escapeshellarg($global[\u0027systemRootPath\u0027] . \u0027plugin/Live/on_publish_socket_notification.php\u0027)\n+ . \u0027 \u0027 . escapeshellarg((string) $users_id)\n+ . \u0027 \u0027 . escapeshellarg((string) $m3u8)\n+ . \u0027 \u0027 . escapeshellarg((string) $obj-\u003eliveTransmitionHistory_id);\n _error_log(\"NGINX Live::on_publish YPTSocket start ($command)\");\n $pid = execAsync($command);\n }\n```\n\nDefence-in-depth: `on_publish.php` is the nginx-rtmp webhook and should not be reachable from the public Internet. Add an `.htaccess`/nginx `location` rule restricting the file to `127.0.0.1` and any configured RTMP server IPs. That blocks the trigger path independently of the sanitisation work.",
"id": "GHSA-xw67-cg5f-4m2r",
"modified": "2026-06-09T10:27:13Z",
"published": "2026-05-15T18:32:36Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/WWBN/AVideo/security/advisories/GHSA-xw67-cg5f-4m2r"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-45578"
},
{
"type": "PACKAGE",
"url": "https://github.com/WWBN/AVideo"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
],
"summary": "AVideo: OS command injection in on_publish.php execAsync via unescaped m3u8 URL"
}
GHSA-XW73-FCCW-FGC4
Vulnerability from github – Published: 2026-02-18 18:30 – Updated: 2026-02-18 18:30ZoneMinder v1.36.34 is vulnerable to Command Injection in web/views/image.php. The application passes unsanitized user input directly to the exec() function.
{
"affected": [],
"aliases": [
"CVE-2025-65791"
],
"database_specific": {
"cwe_ids": [
"CWE-78"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2026-02-18T16:22:29Z",
"severity": "CRITICAL"
},
"details": "ZoneMinder v1.36.34 is vulnerable to Command Injection in web/views/image.php. The application passes unsanitized user input directly to the exec() function.",
"id": "GHSA-xw73-fccw-fgc4",
"modified": "2026-02-18T18:30:39Z",
"published": "2026-02-18T18:30:39Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2025-65791"
},
{
"type": "WEB",
"url": "https://github.com/rishavand1/CVE-2025-65791"
}
],
"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"
}
]
}
GHSA-XW74-8R5V-3XPV
Vulnerability from github – Published: 2022-05-24 17:48 – Updated: 2022-05-24 17:48An OS command injection vulnerability in the installUpdateThemePluginAction function in index.php in WonderCMS 3.1.3, allows remote attackers to upload a custom plugin which can contain arbitrary code and obtain a webshell via the theme/plugin installer.
{
"affected": [],
"aliases": [
"CVE-2020-35314"
],
"database_specific": {
"cwe_ids": [
"CWE-78"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2021-04-20T20:15:00Z",
"severity": "CRITICAL"
},
"details": "An OS command injection vulnerability in the installUpdateThemePluginAction function in index.php in WonderCMS 3.1.3, allows remote attackers to upload a custom plugin which can contain arbitrary code and obtain a webshell via the theme/plugin installer.",
"id": "GHSA-xw74-8r5v-3xpv",
"modified": "2022-05-24T17:48:01Z",
"published": "2022-05-24T17:48:01Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2020-35314"
},
{
"type": "WEB",
"url": "https://github.com/robiso/wondercms"
},
{
"type": "WEB",
"url": "https://packetstormsecurity.com/files/160311/WonderCMS-3.1.3-Remote-Code-Execution.html"
},
{
"type": "WEB",
"url": "https://zetc0de.github.io/post/authenticated-rce-ssrf-wondercms"
},
{
"type": "WEB",
"url": "https://zetc0de.github.io/post/authenticated-rce-ssrf-wondercms/#authenticated-remote-code-execution"
}
],
"schema_version": "1.4.0",
"severity": []
}
GHSA-XW88-56J3-F38V
Vulnerability from github – Published: 2025-12-11 21:31 – Updated: 2025-12-12 18:30OS Command Injection vulnerability in Ruijie X30-PRO X30-PRO-V1_09241521 allowing attackers to execute arbitrary commands via a crafted POST request to the module_get in file /usr/local/lua/dev_sta/host_access_delay.lua.
{
"affected": [],
"aliases": [
"CVE-2025-56094"
],
"database_specific": {
"cwe_ids": [
"CWE-78"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2025-12-11T19:15:55Z",
"severity": "HIGH"
},
"details": "OS Command Injection vulnerability in Ruijie X30-PRO X30-PRO-V1_09241521 allowing attackers to execute arbitrary commands via a crafted POST request to the module_get in file /usr/local/lua/dev_sta/host_access_delay.lua.",
"id": "GHSA-xw88-56j3-f38v",
"modified": "2025-12-12T18:30:34Z",
"published": "2025-12-11T21:31:30Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2025-56094"
},
{
"type": "WEB",
"url": "https://1drv.ms/f/c/12406a392c92914b/EtGIxwWujwxBvQhL9wgnUIwBkg-mndJJX07Igr6d0cic-g?e=4KJbWY"
},
{
"type": "WEB",
"url": "https://1drv.ms/t/c/12406a392c92914b/EX8LVTGd3L9OrXvTuHDFITQBnWL-5C-CINxUmowR7vCVig?e=Quevaq"
},
{
"type": "WEB",
"url": "https://github.com/flegoity/Ruijie-Multiple-Devices-Vulnerability-Reports-for-CVE/blob/main/CVE-2025-56094.md"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-XW9J-H8X5-JQMQ
Vulnerability from github – Published: 2022-05-24 16:56 – Updated: 2024-04-04 02:00A vulnerability in a CLI command related to the virtualization manager (VMAN) in Cisco NX-OS Software could allow an authenticated, local attacker to execute arbitrary commands on the underlying Linux operating system with root privileges. The vulnerability is due to insufficient validation of arguments passed to a specific VMAN CLI command on an affected device. An attacker could exploit this vulnerability by including malicious input as the argument of an affected command. A successful exploit could allow the attacker to execute arbitrary commands on the underlying Linux operating system with root privileges, which may lead to complete system compromise. An attacker would need valid administrator credentials to exploit this vulnerability.
{
"affected": [],
"aliases": [
"CVE-2019-12717"
],
"database_specific": {
"cwe_ids": [
"CWE-78"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2019-09-25T21:15:00Z",
"severity": "HIGH"
},
"details": "A vulnerability in a CLI command related to the virtualization manager (VMAN) in Cisco NX-OS Software could allow an authenticated, local attacker to execute arbitrary commands on the underlying Linux operating system with root privileges. The vulnerability is due to insufficient validation of arguments passed to a specific VMAN CLI command on an affected device. An attacker could exploit this vulnerability by including malicious input as the argument of an affected command. A successful exploit could allow the attacker to execute arbitrary commands on the underlying Linux operating system with root privileges, which may lead to complete system compromise. An attacker would need valid administrator credentials to exploit this vulnerability.",
"id": "GHSA-xw9j-h8x5-jqmq",
"modified": "2024-04-04T02:00:09Z",
"published": "2022-05-24T16:56:50Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2019-12717"
},
{
"type": "WEB",
"url": "https://tools.cisco.com/security/center/content/CiscoSecurityAdvisory/cisco-sa-20190925-nxos-vman-cmd-inj"
}
],
"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-XWCJ-W2W2-2G7C
Vulnerability from github – Published: 2025-07-25 03:30 – Updated: 2025-07-25 03:30The WP Database Backup plugin for WordPress is vulnerable to OS Command Injection in versions before 5.2 via the mysqldump function. This vulnerability allows unauthenticated attackers to execute arbitrary commands on the host operating system.
{
"affected": [],
"aliases": [
"CVE-2019-25224"
],
"database_specific": {
"cwe_ids": [
"CWE-78"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2025-07-25T03:15:32Z",
"severity": "CRITICAL"
},
"details": "The WP Database Backup plugin for WordPress is vulnerable to OS Command Injection in versions before 5.2 via the mysqldump function. This vulnerability allows unauthenticated attackers to execute arbitrary commands on the host operating system.",
"id": "GHSA-xwcj-w2w2-2g7c",
"modified": "2025-07-25T03:30:27Z",
"published": "2025-07-25T03:30:27Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2019-25224"
},
{
"type": "WEB",
"url": "https://blog.sucuri.net/2019/06/os-command-injection-in-wp-database-backup.html"
},
{
"type": "WEB",
"url": "https://packetstormsecurity.com/files/153781"
},
{
"type": "WEB",
"url": "https://plugins.trac.wordpress.org/changeset/2078035/wp-database-backup"
},
{
"type": "WEB",
"url": "https://raw.githubusercontent.com/rapid7/metasploit-framework/master/modules/exploits/multi/http/wp_db_backup_rce.rb"
},
{
"type": "WEB",
"url": "https://www.wordfence.com/blog/2019/05/os-command-injection-vulnerability-patched-in-wp-database-backup-plugin"
},
{
"type": "WEB",
"url": "https://www.wordfence.com/threat-intel/vulnerabilities/id/d21cf285-9d75-43a2-9e81-67116f0bf896?source=cve"
}
],
"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"
}
]
}
GHSA-XWCM-X564-9RVC
Vulnerability from github – Published: 2023-07-06 15:30 – Updated: 2025-11-04 21:30Two OS command injection vulnerabilities exist in the urvpn_client cmd_name_action functionality of Milesight UR32L v32.3.0.5. A specially crafted network request can lead to arbitrary command execution. An attacker can send a network request to trigger these vulnerabilities.This OS command injection is triggered through a TCP packet.
{
"affected": [],
"aliases": [
"CVE-2023-24582"
],
"database_specific": {
"cwe_ids": [
"CWE-77",
"CWE-78"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2023-07-06T15:15:12Z",
"severity": "HIGH"
},
"details": "Two OS command injection vulnerabilities exist in the urvpn_client cmd_name_action functionality of Milesight UR32L v32.3.0.5. A specially crafted network request can lead to arbitrary command execution. An attacker can send a network request to trigger these vulnerabilities.This OS command injection is triggered through a TCP packet.",
"id": "GHSA-xwcm-x564-9rvc",
"modified": "2025-11-04T21:30:34Z",
"published": "2023-07-06T15:30:34Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2023-24582"
},
{
"type": "WEB",
"url": "https://talosintelligence.com/vulnerability_reports/TALOS-2023-1710"
},
{
"type": "WEB",
"url": "https://www.talosintelligence.com/vulnerability_reports/TALOS-2023-1710"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-XWFH-QQWW-GR22
Vulnerability from github – Published: 2023-03-19 03:30 – Updated: 2025-11-03 21:30org-babel-execute:latex in ob-latex.el in Org Mode through 9.6.1 for GNU Emacs allows attackers to execute arbitrary commands via a file name or directory name that contains shell metacharacters.
{
"affected": [],
"aliases": [
"CVE-2023-28617"
],
"database_specific": {
"cwe_ids": [
"CWE-78"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2023-03-19T03:15:00Z",
"severity": "CRITICAL"
},
"details": "org-babel-execute:latex in ob-latex.el in Org Mode through 9.6.1 for GNU Emacs allows attackers to execute arbitrary commands via a file name or directory name that contains shell metacharacters.",
"id": "GHSA-xwfh-qqww-gr22",
"modified": "2025-11-03T21:30:47Z",
"published": "2023-03-19T03:30:25Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2023-28617"
},
{
"type": "WEB",
"url": "https://git.savannah.gnu.org/cgit/emacs/org-mode.git/commit/?id=8f8ec2ccf3f5ef8f38d68ec84a7e4739c45db485"
},
{
"type": "WEB",
"url": "https://git.savannah.gnu.org/cgit/emacs/org-mode.git/commit/?id=a8006ea580ed74f27f974d60b598143b04ad1741"
},
{
"type": "WEB",
"url": "https://list.orgmode.org/tencent_04CF842704737012CCBCD63CD654DD41CA0A%40qq.com/T/#m6ef8e7d34b25fe17b4cbb655b161edce18c6655e"
},
{
"type": "WEB",
"url": "https://list.orgmode.org/tencent_04CF842704737012CCBCD63CD654DD41CA0A@qq.com/T/#m6ef8e7d34b25fe17b4cbb655b161edce18c6655e"
},
{
"type": "WEB",
"url": "https://lists.debian.org/debian-lts-announce/2023/05/msg00008.html"
},
{
"type": "WEB",
"url": "https://lists.debian.org/debian-lts-announce/2023/10/msg00019.html"
},
{
"type": "WEB",
"url": "https://lists.debian.org/debian-lts-announce/2025/02/msg00033.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"
}
]
}
GHSA-XWJG-QXV6-28RV
Vulnerability from github – Published: 2022-07-22 00:00 – Updated: 2022-07-28 00:00Multiple vulnerabilities in Cisco Nexus Dashboard could allow an unauthenticated, remote attacker to execute arbitrary commands, read or upload container image files, or perform a cross-site request forgery attack. For more information about these vulnerabilities, see the Details section of this advisory.
{
"affected": [],
"aliases": [
"CVE-2022-20857"
],
"database_specific": {
"cwe_ids": [
"CWE-306",
"CWE-78"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2022-07-21T04:15:00Z",
"severity": "CRITICAL"
},
"details": "Multiple vulnerabilities in Cisco Nexus Dashboard could allow an unauthenticated, remote attacker to execute arbitrary commands, read or upload container image files, or perform a cross-site request forgery attack. For more information about these vulnerabilities, see the Details section of this advisory.",
"id": "GHSA-xwjg-qxv6-28rv",
"modified": "2022-07-28T00:00:41Z",
"published": "2022-07-22T00:00:39Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2022-20857"
},
{
"type": "WEB",
"url": "https://tools.cisco.com/security/center/content/CiscoSecurityAdvisory/cisco-sa-ndb-mhcvuln-vpsBPJ9y"
}
],
"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"
}
]
}
Mitigation
If at all possible, use library calls rather than external processes to recreate the desired functionality.
Mitigation MIT-22
Strategy: Sandbox or Jail
- Run the code in a "jail" or similar sandbox environment that enforces strict boundaries between the process and the operating system. This may effectively restrict which files can be accessed in a particular directory or which commands can be executed by the software.
- OS-level examples include the Unix chroot jail, AppArmor, and SELinux. In general, managed code may provide some protection. For example, java.io.FilePermission in the Java SecurityManager allows the software to specify restrictions on file operations.
- This may not be a feasible solution, and it only limits the impact to the operating system; the rest of the application may still be subject to compromise.
- Be careful to avoid CWE-243 and other weaknesses related to jails.
Mitigation
Strategy: Attack Surface Reduction
For any data that will be used to generate a command to be executed, keep as much of that data out of external control as possible. For example, in web applications, this may require storing the data locally in the session's state instead of sending it out to the client in a hidden form field.
Mitigation MIT-15
For any security checks that are performed on the client side, ensure that these checks are duplicated on the server side, in order to avoid CWE-602. Attackers can bypass the client-side checks by modifying values after the checks have been performed, or by changing the client to remove the client-side checks entirely. Then, these modified values would be submitted to the server.
Mitigation MIT-4.3
Strategy: Libraries or Frameworks
- Use a vetted library or framework that does not allow this weakness to occur or provides constructs that make this weakness easier to avoid.
- For example, consider using the ESAPI Encoding control [REF-45] or a similar tool, library, or framework. These will help the programmer encode outputs in a manner less prone to error.
Mitigation MIT-28
Strategy: Output Encoding
While it is risky to use dynamically-generated query strings, code, or commands that mix control and data together, sometimes it may be unavoidable. Properly quote arguments and escape any special characters within those arguments. The most conservative approach is to escape or filter all characters that do not pass an extremely strict allowlist (such as everything that is not alphanumeric or white space). If some special characters are still needed, such as white space, wrap each argument in quotes after the escaping/filtering step. Be careful of argument injection (CWE-88).
Mitigation
If the program to be executed allows arguments to be specified within an input file or from standard input, then consider using that mode to pass arguments instead of the command line.
Mitigation MIT-27
Strategy: Parameterization
- If available, use structured mechanisms that automatically enforce the separation between data and code. These mechanisms may be able to provide the relevant quoting, encoding, and validation automatically, instead of relying on the developer to provide this capability at every point where output is generated.
- Some languages offer multiple functions that can be used to invoke commands. Where possible, identify any function that invokes a command shell using a single string, and replace it with a function that requires individual arguments. These functions typically perform appropriate quoting and filtering of arguments. For example, in C, the system() function accepts a string that contains the entire command to be executed, whereas execl(), execve(), and others require an array of strings, one for each argument. In Windows, CreateProcess() only accepts one command at a time. In Perl, if system() is provided with an array of arguments, then it will quote each of the arguments.
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.
- When constructing OS command strings, use stringent allowlists that limit the character set based on the expected value of the parameter in the request. This will indirectly limit the scope of an attack, but this technique is less important than proper output encoding and escaping.
- Note that proper output encoding, escaping, and quoting is the most effective solution for preventing OS command injection, although input validation may provide some defense-in-depth. This is because it effectively limits what will appear in output. Input validation will not always prevent OS command injection, especially if you are required to support free-form text fields that could contain arbitrary characters. For example, when invoking a mail program, you might need to allow the subject field to contain otherwise-dangerous inputs like ";" and ">" characters, which would need to be escaped or otherwise handled. In this case, stripping the character might reduce the risk of OS command injection, but it would produce incorrect behavior because the subject field would not be recorded as the user intended. This might seem to be a minor inconvenience, but it could be more important when the program relies on well-structured subject lines in order to pass messages to other components.
- Even if you make a mistake in your validation (such as forgetting one out of 100 input fields), appropriate encoding is still likely to protect you from injection-based attacks. As long as it is not done in isolation, input validation is still a useful technique, since it may significantly reduce your attack surface, allow you to detect some attacks, and provide other security benefits that proper encoding does not address.
Mitigation MIT-21
Strategy: Enforcement by Conversion
When the set of acceptable objects, such as filenames or URLs, is limited or known, create a mapping from a set of fixed input values (such as numeric IDs) to the actual filenames or URLs, and reject all other inputs.
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 MIT-39
- Ensure that error messages only contain minimal details that are useful to the intended audience and no one else. The messages need to strike the balance between being too cryptic (which can confuse users) or being too detailed (which may reveal more than intended). The messages should not reveal the methods that were used to determine the error. Attackers can use detailed information to refine or optimize their original attack, thereby increasing their chances of success.
- If errors must be captured in some detail, record them in log messages, but consider what could occur if the log messages can be viewed by attackers. Highly sensitive information such as passwords should never be saved to log files.
- Avoid inconsistent messaging that might accidentally tip off an attacker about internal state, such as whether a user account exists or not.
- In the context of OS Command Injection, error information passed back to the user might reveal whether an OS command is being executed and possibly which command is being used.
Mitigation
Strategy: Sandbox or Jail
Use runtime policy enforcement to create an allowlist of allowable commands, then prevent use of any command that does not appear in the allowlist. Technologies such as AppArmor are available to do this.
Mitigation MIT-29
Strategy: Firewall
Use an application firewall that can detect attacks against this weakness. It can be beneficial in cases in which the code cannot be fixed (because it is controlled by a third party), as an emergency prevention measure while more comprehensive software assurance measures are applied, or to provide defense in depth [REF-1481].
Mitigation MIT-17
Strategy: Environment Hardening
Run your code using the lowest privileges that are required to accomplish the necessary tasks [REF-76]. If possible, create isolated accounts with limited privileges that are only used for a single task. That way, a successful attack will not immediately give the attacker access to the rest of the software or its environment. For example, database applications rarely need to run as the database administrator, especially in day-to-day operations.
Mitigation MIT-16
Strategy: Environment Hardening
When using PHP, configure the application so that it does not use register_globals. During implementation, develop the application so that it does not rely on this feature, but be wary of implementing a register_globals emulation that is subject to weaknesses such as CWE-95, CWE-621, and similar issues.
CAPEC-108: Command Line Execution through SQL Injection
An attacker uses standard SQL injection methods to inject data into the command line for execution. This could be done directly through misuse of directives such as MSSQL_xp_cmdshell or indirectly through injection of data into the database that would be interpreted as shell commands. Sometime later, an unscrupulous backend application (or could be part of the functionality of the same application) fetches the injected data stored in the database and uses this data as command line arguments without performing proper validation. The malicious data escapes that data plane by spawning new commands to be executed on the host.
CAPEC-15: Command Delimiters
An attack of this type exploits a programs' vulnerabilities that allows an attacker's commands to be concatenated onto a legitimate command with the intent of targeting other resources such as the file system or database. The system that uses a filter or denylist input validation, as opposed to allowlist validation is vulnerable to an attacker who predicts delimiters (or combinations of delimiters) not present in the filter or denylist. As with other injection attacks, the attacker uses the command delimiter payload as an entry point to tunnel through the application and activate additional attacks through SQL queries, shell commands, network scanning, and so on.
CAPEC-43: Exploiting Multiple Input Interpretation Layers
An attacker supplies the target software with input data that contains sequences of special characters designed to bypass input validation logic. This exploit relies on the target making multiples passes over the input data and processing a "layer" of special characters with each pass. In this manner, the attacker can disguise input that would otherwise be rejected as invalid by concealing it with layers of special/escape characters that are stripped off by subsequent processing steps. The goal is to first discover cases where the input validation layer executes before one or more parsing layers. That is, user input may go through the following logic in an application: <parser1> --> <input validator> --> <parser2>. In such cases, the attacker will need to provide input that will pass through the input validator, but after passing through parser2, will be converted into something that the input validator was supposed to stop.
CAPEC-6: Argument Injection
An attacker changes the behavior or state of a targeted application through injecting data or command syntax through the targets use of non-validated and non-filtered arguments of exposed services or methods.
CAPEC-88: OS Command Injection
In this type of an attack, an adversary injects operating system commands into existing application functions. An application that uses untrusted input to build command strings is vulnerable. An adversary can leverage OS command injection in an application to elevate privileges, execute arbitrary commands and compromise the underlying operating system.