/

CVE-2026-34117

Severity:

CRITICAL RISK

(9.8)

OS Command Injection (CWE-78) in Guardian exec Call

CVE-2026-34117

Deferred

Vulnerability type

Category:

OS Command Injection

CWE:

CWE-78

Impact:

Remote Code Execution

Severity:

CRITICAL RISK

(9.8)

CVSS version:

3.1

Catch this CVE while code is being written

Detect vulnerable code directly in pull requests, so CVEs are fixed before merge.

Summary

Guardian language-system contains an OS command injection flaw where an HTTP GET parameter is concatenated directly into a PHP exec() call without sanitization.

An unauthenticated remote attacker can craft a request with shell metacharacters in the id parameter to execute arbitrary operating system commands on the server.

Affected context

This vulnerability occurs in deployments of the Guardian language-system that expose the text_to_subtitles.php endpoint to untrusted clients.

The issue arises when the application constructs a shell command using PHP exec() and directly interpolates the id GET parameter, without input validation, escaping, or use of safer process-spawning primitives.

Any environment where this endpoint is reachable over a network and mapped to an active PHP interpreter may be affected, regardless of authentication configuration.

Exploit preconditions

  • Attack surface: HTTP interface to text_to_subtitles.php
  • Required access: None; the endpoint is reachable without authentication
  • Trigger point: A request supplying a crafted id GET parameter that is included in the exec() command line
  • Why exploitation is possible: The id parameter is concatenated into a shell command string and executed, allowing shell metacharacters and additional commands to be interpreted by the underlying shell

Why this happens

The root cause is unsafely constructing shell commands using user-controlled input and passing them to PHP exec(), aligning with CWE-78: Improper Neutralization of Special Elements used in an OS Command.

Instead of treating user input as opaque data, the code interpolates the id parameter directly into the command string, enabling attackers to inject shell syntax (e.g., separators, redirection, pipelines) that the shell interprets as new commands or arguments.

This pattern reflects a broader bug class where applications delegate work to the operating system shell without proper escaping, validation, or use of parameterized process execution APIs.

Potential impact

  • Execution of arbitrary OS commands with the web server or PHP process privileges
  • Reading, modifying, or deleting files accessible to the application user
  • Installation of backdoors, web shells, or additional malicious tooling
  • Access to sensitive configuration data such as database credentials or API keys
  • Lateral movement within the hosting environment or internal network, depending on privileges
  • Service disruption or denial-of-service by terminating processes or exhausting system resources

General mitigation guidance

Effective mitigation focuses on removing direct shell command construction with user input and minimizing reliance on the shell.

Common defensive patterns include:

  • Replacing exec()-based shell calls with language-level APIs (e.g., PHP functions or libraries) that perform the desired operation without invoking a shell
  • When external processes are truly necessary, using process execution APIs that pass arguments as arrays (e.g., proc_open with escapeshellarg or equivalent), avoiding shell interpretation
  • Strictly validating and constraining any external parameters (e.g., whitelisting ids against known formats or enumerations instead of accepting arbitrary strings)
  • Running the web application under a minimally privileged account and isolating it via containers or chroot where appropriate, to reduce the blast radius of a compromise
  • Applying a defense-in-depth input validation strategy so that externally sourced values are treated as untrusted and normalized early in request handling

How teams detect issues like this

Detection typically combines code-centric and behavior-centric approaches:

  • Static code analysis rules that flag use of exec(), system(), shell_exec(), and similar functions when concatenated with superglobals like $_GET, $_POST, or $_REQUEST
  • Code review practices that require justification and scrutiny for any shell invocation, looking specifically for string concatenation involving external input
  • Security linters or CI checks configured to block merges when unsafe command construction is detected
  • Runtime monitoring of process creation by the web server user, alerting on unusual commands or arguments indicative of injection
  • Web application firewall (WAF) or reverse proxy rules that detect and optionally block requests containing obvious shell metacharacters in parameters known to be at risk

Sources

SourceLink
gist.github.comgist.github.com/cyberinforepo/d5b2771d82e1b31b8fc1c33052e08dad
vulncheck.comvulncheck.com/advisories/guardian-language-system-unauthenticated-os-command-injection-via-id-parameter-in-text-to-subtitles-php

Frequently asked

questions

Yes. Because the vulnerable script accepts the id parameter over HTTP without authentication, an attacker can exploit it remotely by sending crafted requests to the exposed endpoint.

No authenticated access is required. The attacker only needs network access to reach the text_to_subtitles.php script, such as via a public-facing web server or an internal application endpoint.

The safest pattern is to eliminate direct shell invocation with user input: implement the text-to-subtitles logic using native language constructs or libraries, and if external tools are required, invoke them with parameterized APIs that treat user input as data, not as part of a shell command.

Adopt secure coding standards that prohibit concatenating untrusted input into command strings, enforce automated checks for risky APIs in CI, and design application components so user-controlled data is validated, constrained, and passed as parameters rather than as executable instructions.

Find out what's already
exploitable in your codebase.