Attack ChainAIDerived
Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain
-
AccessObtain ZLMediaKit API secret
-
DeliveryIdentify sibling directory sharing root name prefix
-
ExploitCraft file path bypassing prefix-only confinement check
-
ExecutionSend authenticated request to downloadFile API endpoint
-
PersistReceive file contents read by server process
-
ImpactExfiltrate credentials or keys from host filesystem
Vulnerability Assessment
| Weakness |
CWE
OWASP Top 10:2025
A01:2025 - Broken Access Control
ASVS 5.0
V5 - File Handling Path canonicalization, traversal prevention
MITRE ATT&CK
2 techniques across 2 tactics: Discovery, Collection The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up. |
| Exploitation Conditions | Exploitation requires prior possession of the configured ZLMediaKit API secret; the secret check executes before the path traversal logic, and without it the endpoint rejects all requests (CVSS PR:H). The attacker must also know or enumerate sibling directory names that share a prefix with the configured root - knowledge of the server's filesystem layout is therefore a secondary prerequisite. The vulnerability is strictly limited to the downloadFile API handler in server/WebApi.cpp; the standard static file server is not affected. The attack produces read-only access - no write, delete, or code-execution primitive is exposed by this flaw alone. The impact ceiling is bounded by the OS privileges of the ZLMediaKit process: the reference container runs as root (maximum exposure), but deployments using a dedicated non-root service account would expose only files readable by that account. |
| Impact | The CVSS 4.0 vector (AV:N/AC:L/AT:N/PR:H/VC:H) correctly captures the core tension: this is a network-accessible endpoint but is gated behind a high-privilege API secret, substantially narrowing the realistic attacker population to insiders, credential-theft victims, or environments where the secret has been inadvertently exposed. The confidentiality impact is rated High because the reference container runs as root, meaning a successful exploitation exposes the full host filesystem - private keys, environment files, and operator credentials included - with no integrity or availability impact. No EPSS score was provided and the vulnerability is not listed in the CISA KEV catalog; no public exploit code has been identified at time of analysis. The overall risk posture is moderate rather than critical: this is not a zero-authentication flaw that mass scanners would opportunistically exploit, and any deployment where the API secret is tightly controlled faces a substantially lower practical risk than the impact ceiling suggests. However, operators running ZLMediaKit as root in containerized environments who have broadly shared or logged the API secret should treat remediation as urgent, since the attack is low-complexity once the secret is known. |
| Exploit ScenarioDerived | An attacker who has obtained the ZLMediaKit API secret - through credential theft, log exposure, or insider access - sends an authenticated HTTP request to the downloadFile endpoint specifying a path such as /srv/media-private/app.env, where /srv/media is the configured root. Because the prefix check compares /srv/media against /srv/media-private without a separator, the guard passes and the server returns the file contents. No dot-dot sequences are required, and if the process runs as root the attacker can target any readable file on the host. |
Get an e-mail when this CVE is exploited, patched or re-scored. Free account.
Alert meAnalysisAIv1 – Aug 26, 2026
Path traversal in ZLMediaKit's downloadFile API allows an authenticated operator holding the API secret to read files from sibling directories outside the configured root, because the root path is built without a trailing separator and the confinement check is a bare prefix comparison. The flaw is isolated to server/WebApi.cpp and does not affect the standard static file server in src/Http/HttpFileManager.cpp. No patch version has been confirmed and no public exploit has been identified at time of analysis, but because the reference container runs as root, a secret-holding attacker can read arbitrary host filesystem content.
RemediationAI
No vendor-released patched version has been confirmed at time of analysis; operators should monitor the ZLMediaKit GitHub repository (https://github.com/ZLMediaKit/ZLMediaKit) and issue #4817 for an upstream fix and apply it promptly when released. As an immediate compensating control, restrict network-level access to the downloadFile API endpoint using firewall rules or reverse-proxy ACLs so that only explicitly authorized hosts can reach it - this reduces the attack surface to the most-trusted API consumers. Rotate the API secret immediately if there is any possibility it has been exposed in logs, configuration management systems, or shared credentials stores. Audit recent downloadFile request logs for path strings that begin with a configured root directory name but extend beyond it into sibling paths. If ZLMediaKit is running in a container as root, reconfigure the service to run under a dedicated non-root user account; this does not fix the traversal logic but reduces the impact ceiling from full-filesystem read to only files accessible by that service account, which is a meaningful reduction. The trade-off of a non-root mitigation is that it may require filesystem permission adjustments on media directories.
Affected VersionsENISA
Affects your stack
Find out whether the stacks and servers you run are on an affected version.
Checking this CVE against your own stacks and servers is part of the Basic plan and up.
Technical ContextAI · show details
ZLMediaKit (CPE: cpe:2.3:a:zlmediakit:zlmediakit:*:*:*:*:*:*:*:*) is an open-source C++ streaming media framework supporting RTSP, RTMP, HLS, and HTTP-FLV protocols. The downloadFile API handler in server/WebApi.cpp is supposed to confine file serving to operator-configured root directories, but constructs each root by calling File::absolutePath("", item, true) with an empty relative argument. That helper returns the path without a trailing directory separator under these conditions, so the guard condition start_with(file_path, root) can be satisfied by any sibling directory whose name merely begins with the configured root string - for example, if the root is /srv/media, a request targeting /srv/media-archive/secrets.env passes the check. CWE-22 (Improper Limitation of a Pathname to a Restricted Directory) applies precisely: the comparison is not directory-boundary-aware. The secondary guard that rejects paths containing two consecutive dots is irrelevant here because no dot-dot traversal sequences are required. The standard static file server in src/Http/HttpFileManager.cpp passes a non-empty second argument to the same helper, causing a separator to be appended before comparison, and is therefore not affected.
Know when Zlmediakit gets its next vulnerability
- Watch products and get an email when something new is published
- Check this CVE against your own stack and servers
- Exploit and PoC references, threat intelligence from 22 sources
No credit card · 7-day full trial
Severity by source
CVSS:4.0/AV:N/AC:L/AT:N/PR:H/UI:N/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N
Network-accessible endpoint requires high-privilege API secret; traversal is read-only with no integrity, availability, or scope-change impact.
Primary rating from Vendor (VulnCheck).
CVSS VectorVendor: VulnCheck
DescriptionCVE.org
ZLMediaKit confines the downloadFile API to a configured set of root directories with a prefix comparison that does not account for directory boundaries. The configuration loader in server/WebApi.cpp builds each root with File::absolutePath("", item, true); because the relative-path argument is empty that helper returns the value without a trailing separator. The handler then accepts a requested path when start_with(file_path, root) holds, so a sibling directory whose name merely begins with the configured root string satisfies the test and is served. The only other guard rejects a path containing two dots, which this requires none of. The equivalent confinement check for the ordinary static file server in src/Http/HttpFileManager.cpp computes its root with a non-empty second argument, which appends the separator before comparing, and so is not affected. The endpoint requires the configured API secret, so this grants no privilege beyond what that secret already implies, but it reads files outside the directory the operator confined it to, and the reference container runs the server as root.
Threat Intelligence Overview
How this decision was reached
The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.
What every action level means
SSVC AssessmentENISA
Priority Score
Attack Technique
Path traversal exploits occur when applications use user-controlled input to construct file system paths without proper validation.
More in Zlmediakit
View allZLMediaKit 4.0 is vulnerable to Directory Traversal. Rated high severity (CVSS 7.5), this vulnerability is remotely expl
Unauthenticated remote code execution affects ZLMediaKit builds based on commit 9fd5152, where broken access control in
Heap buffer overflow in ZLMediaKit's VP9 RTP payload parser allows remote unauthenticated attackers to trigger denial of
An attacker can send malicious RTMP requests to make the ZLMediaKit server crash remotely. Rated high severity (CVSS 7.5
Cross Site Scripting vulnerability in ZLMediaKiet v.4.0 and v.5.0 allows an attacker to execute arbitrary code via a cra
EUVD-2026-66604
GHSA-4j5x-jgmh-j582
NVD
CVE.org
EPSS
Exploit-DB