CVE-2026-8023: Zephyr HTTP Server Path Traversal – Information Disclosure
Zephyr's HTTP server has a path-traversal vulnerability in its static file serving feature. When configured to serve files from a specific directory, the server fails to properly validate request paths, allowing an attacker to use sequences like ../../ to escape the intended directory and read arbitrary files on the system. An unauthenticated remote attacker can exploit this over the network without encryption or authentication—they simply craft a specially-formed HTTP request to retrieve sensitive files they shouldn't have access to.
Source data · NVD / CISA · public domain
- CVSS
- 3.1 · 7.5 HIGH · CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
- Weaknesses (CWE)
- CWE-22, CWE-23
- Affected products
- 1 configuration(s)
- Published / Modified
- 2026-06-29 / 2026-07-17
NVD description (verbatim)
Zephyr's HTTP server (subsys/net/lib/http) provides a static-filesystem resource type (HTTP_RESOURCE_TYPE_STATIC_FS, available when CONFIG_FILE_SYSTEM is enabled) that serves files from a configured root directory. Before this fix, both the HTTP/1 and HTTP/2 front-ends placed the raw, attacker-controlled request path into client->url_buffer (assembled in on_url() for HTTP/1 and copied verbatim from the :path pseudo-header for HTTP/2) without resolving ./.. segments. The static-FS handler then built the on-disk filename by directly concatenating the configured root with that raw URL (snprintk(fname, ..., "%s%s", static_fs_detail->fs_path, client->url_buffer) at http_server_http1.c:603 and http_server_http2.c:490) and opened it with fs_open(fname, FS_O_READ). Because the handler is reached via wildcard/leading-dir (fnmatch FNM_LEADING_DIR) or fallback resource matching, a request such as GET /<prefix>/../../<file> is dispatched to the handler and, after the underlying filesystem (e.g. LittleFS/FAT) resolves the .. segments, escapes the configured web root, letting an unauthenticated remote client read arbitrary readable files on the mounted volume (information disclosure). The HTTP server requires no TLS or authentication to reach this path. The fix adds http_server_remove_dot_segments(), which canonicalizes the path portion of the URL before resource lookup in both protocol handlers, neutralizing the traversal. Affects releases v4.0.0 through v4.4.0 for deployments that register a static-filesystem resource.
3 reference(s) · View on NVD →
SEC.co analysis · AI-assisted, reviewed against source
Technical summary
The vulnerability exists in Zephyr's HTTP subsystem (subsys/net/lib/http) when CONFIG_FILE_SYSTEM is enabled and a static-filesystem resource is registered. Both HTTP/1 and HTTP/2 protocol handlers accept the raw request path (from the HTTP/1 request line or HTTP/2 :path pseudo-header) and pass it directly to the resource handler without canonicalization. The static-FS handler then concatenates the configured root directory with the untreated URL and opens the resulting file via fs_open(). Because the underlying filesystem (e.g. LittleFS, FAT) independently resolves .. segments, an attacker-controlled request path containing ./ and ../ sequences bypasses the intended root boundary. Path canonicalization via http_server_remove_dot_segments() is now performed before resource dispatch to both HTTP/1 and HTTP/2 handlers, neutralizing directory traversal.
Business impact
Zephyr devices serving web content via the HTTP server (including IoT, embedded edge devices, and industrial control systems) risk exposure of sensitive data stored on their filesystems. An attacker can remotely enumerate and retrieve configuration files, firmware images, private keys, credentials, logs, or other files resident on accessible storage—without authentication or encryption—potentially leading to further system compromise, credential theft, or supply-chain attacks if the device is part of a managed fleet.
Affected systems
Zephyr releases v4.0.0 through v4.4.0 are affected when: (1) CONFIG_FILE_SYSTEM is enabled, and (2) a static-filesystem resource (HTTP_RESOURCE_TYPE_STATIC_FS) is registered in the application's HTTP server configuration. Devices or applications that do not register a static-FS resource, or that do not enable filesystem support, are not vulnerable. Verify your application's Kconfig and HTTP resource registration to determine exposure.
Exploitability
Exploitability is high. The vulnerability requires no authentication, encryption, or special setup—only network access to the HTTP server. Exploitation is trivial: a simple GET request with a crafted path (e.g., GET /prefix/../../etc/config) is sufficient. An attacker needs no knowledge of the filesystem layout beyond the configured root; fuzzing of .. sequences will reveal readable files. No special tools, timing, or user interaction are required. CVSS 7.5 (HIGH) reflects the ease of exploitation and the high confidentiality impact.
Remediation
Update to a patched version of Zephyr (v4.4.1 or later, or verify against the vendor advisory for your release branch). The fix implements http_server_remove_dot_segments(), which canonicalizes request paths before the static-FS handler receives them. Apply the patch, rebuild, and redeploy. As an interim mitigation, disable the static-FS resource handler if it is not essential, or restrict network access to the HTTP server via firewall rules. Do not rely on the filesystem's pathname visibility as a security boundary.
Patch guidance
Zephyr maintainers have released fixes in patched versions after v4.4.0. Consult the official Zephyr security advisory and release notes to identify the minimum patched version for your release branch (v4.0.x, v4.1.x, etc.). Update your Zephyr SDK and rebuild all affected applications. After patching, confirm that http_server_remove_dot_segments() is called in the HTTP/1 and HTTP/2 path handlers before resource lookup. Test with path-traversal payloads (e.g., GET /../../../etc/passwd) to verify the fix is in place.
Detection guidance
Monitor HTTP server logs for requests containing ./ or ../ segments in the URL path. These are highly indicative of traversal attempts and should trigger alerts. Log all file-open attempts from the HTTP handler, including the resolved filename; compare against the expected root directory to detect out-of-bounds accesses. Network intrusion detection rules can flag HTTP requests with encoded or raw .. sequences. On resource-constrained devices, sample HTTP logs and flag anomalies. Consider deploying a reverse proxy (if possible) that validates and canonicalizes paths before forwarding to the Zephyr HTTP server.
Why prioritize this
HIGH priority. The vulnerability is unauthenticated, remotely exploitable without user interaction, and results in arbitrary information disclosure. It affects embedded and IoT devices that often store sensitive configuration and firmware on accessible filesystems. The fix is straightforward (path canonicalization) and patched versions are available. Organizations using Zephyr v4.0–v4.4 with static-FS resources should prioritize patching within 30 days to prevent data exfiltration and downstream attacks leveraging exposed credentials or configuration.
Risk score, explained
CVSS 3.1 score of 7.5 (HIGH) is assigned because: (1) Attack Vector is Network—no physical or local access needed. (2) Attack Complexity is Low—no special conditions or timing. (3) Privileges Required: None—unauthenticated. (4) User Interaction: None—attacker-controlled request suffices. (5) Scope: Unchanged—impact is on the Zephyr system itself, not other components. (6) Confidentiality Impact: High—arbitrary files can be read. (7) Integrity and Availability: None—the vulnerability only discloses data, does not modify or deny service. The score reflects a realistic and significant risk to production Zephyr deployments serving files over HTTP.
Frequently asked questions
Does this vulnerability affect Zephyr versions before v4.0.0 or after v4.4.0?
No. The vulnerability is specific to releases v4.0.0 through v4.4.0. Earlier versions may have different HTTP server implementations; later versions include the path-canonicalization fix. Always verify your exact version and apply the relevant patch.
If I don't use the static-filesystem resource type, am I safe?
Yes, if your application does not register HTTP_RESOURCE_TYPE_STATIC_FS, you are not vulnerable. However, if you use other dynamic file-serving mechanisms or custom HTTP handlers, review them for similar path-traversal issues. Additionally, CONFIG_FILE_SYSTEM must be enabled for the vulnerability to be exposed; if you have disabled it, the static-FS handler is unavailable.
Can an attacker read files outside the mounted filesystem?
No. The attacker can only traverse files within the mounted volume(s) that the Zephyr HTTP server process can access. However, if your root directory is the top of a large storage volume (e.g., /), then an attacker can read any file accessible to the HTTP process, including sensitive system files, credentials, and firmware. Always mount a dedicated, minimal root directory for the HTTP server.
How do I verify that the patch is installed correctly?
After updating Zephyr and rebuilding, test with a path-traversal payload such as GET /static/../../../../etc/config. A correctly patched server should return a 404 or 403 error, not the requested file. Review the patched source code to confirm http_server_remove_dot_segments() is invoked in http_server_http1.c and http_server_http2.c before the resource lookup.
This analysis is provided for informational purposes to assist security professionals in understanding and remediating CVE-2026-8023. The information reflects the published vulnerability description, CVSS metrics, and available patch guidance as of the publication date. Readers should verify all version numbers, affected products, and patch instructions against official Zephyr security advisories and release notes before implementing any remediation. SEC.co makes no warranty regarding the completeness or accuracy of this content and assumes no liability for decisions made based on this analysis. Always consult your organization's security team and vendor documentation before deploying patches or making configuration changes in production. Source: NVD (public-domain), retrieved 2026-08-08. Analysis generated by SEC.co (claude-haiku-4-5).
Related vulnerabilities
- CVE-2026-50181HIGHLangroid Path Traversal in File Tools – Patch to 0.64.0
- CVE-2026-54066HIGHSiYuan Path Traversal – Unauthenticated File Read in Publish Mode
- CVE-2026-59832HIGHSiYuan Path Traversal Vulnerability – Secrets Disclosure
- CVE-2026-59149MEDIUMMockoon Path Traversal Leads to Unauthorized File Disclosure
- CVE-2016-20076HIGHWordPress Simple-Backup 2.7.11 Unauthenticated File Access & Deletion Vulnerability
- CVE-2016-20081HIGHHB Audio Gallery Lite Path Traversal Vulnerability – Unauthenticated File Download
- CVE-2017-20248HIGHApptha Slider Gallery Path Traversal Vulnerability
- CVE-2017-20250HIGHMac Photo Gallery 3.0 Path Traversal File Download Vulnerability