/

CVE-2026-69095

Severity:

HIGH RISK

(7.5)

Path Traversal (CWE-22) in OpenWrt luci-app-bmx7 CGI

CVE-2026-69095

Deferred

Vulnerability type

Category:

Path Traversal

CWE:

CWE-22

Impact:

Sensitive Information Disclosure

Severity:

HIGH RISK

(7.5)

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

A path traversal vulnerability in the bmx7-info CGI script of OpenWrt luci-app-bmx7 allows attackers to read files outside the intended runtime directory by injecting directory traversal sequences in the query string.

When the CGI process has access to sensitive files, an unauthenticated remote attacker can leverage this flaw to disclose configuration, credential, or other sensitive data from the device.

Affected context

This vulnerability arises in OpenWrt deployments that expose the luci-app-bmx7 web interface and rely on the bmx7-info CGI script to serve runtime data from a configured runtimeDir.

The issue manifests when the script constructs filesystem paths directly from HTTP query parameters without normalizing or constraining them to the intended directory.

Systems where the CGI process user can read sensitive files (such as system configuration, keys, or logs) are at particular risk.

Exploit preconditions

  • Attack surface: HTTP interface of the OpenWrt LuCI web UI exposing the bmx7-info CGI endpoint
  • Required access: No authentication required; attacker only needs network reachability to the web interface
  • Trigger point: Supplying crafted query parameters containing directory traversal sequences (e.g., ../) to the bmx7-info CGI script
  • Why exploitation is possible: The script fails to validate or sanitize user-supplied path components and does not enforce that resolved paths remain inside the configured runtimeDir

Why this happens

The root cause is an improper restriction of file path resolution, corresponding to CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal').

The bmx7-info CGI script likely assembles file paths by concatenating a trusted base directory with untrusted user input, without normalizing the resulting path or checking that it remains within the intended runtimeDir.

This insecure pattern allows ../ sequences in the query string to escape the bounded directory and access arbitrary files readable by the CGI process.

Potential impact

  • Unauthorized reading of system configuration files that may reveal network settings or internal topology
  • Exposure of credentials, tokens, or keys stored in files accessible to the CGI process
  • Leakage of log files that could aid in further attacks or reconnaissance
  • Disclosure of application-specific data stored under or near the runtime directory

General mitigation guidance

Effective mitigation focuses on strictly constraining file access to the intended directory and treating all client-controlled path components as untrusted.

Common defensive patterns include:

  • Normalizing and canonicalizing file paths before access, then verifying they remain within the allowed base directory
  • Using whitelists or fixed filenames rather than directly mapping arbitrary query parameters to filesystem paths
  • Employing filesystem-level controls, such as dedicated service users and restrictive permissions, to limit what the CGI process can read
  • Designing CGI scripts to operate on identifiers or keys mapped to server-side paths, rather than exposing raw path semantics to clients

How teams detect issues like this

Detection can combine code-centric and operational approaches:

  • Static analysis rules looking for use of user input in file path construction without canonicalization or boundary checks
  • Code review checklists that flag any concatenation of HTTP parameters into filesystem paths in CGI or web handlers
  • Runtime monitoring of web server logs for suspicious requests containing directory traversal patterns (e.g., ../, URL-encoded traversal sequences)
  • Security testing and automated scanners that include path traversal payloads against CGI endpoints to detect unexpected file disclosures

Sources

SourceLink
github.comgithub.com/openwrt/luci/security/advisories/GHSA-8qcq-jgrj-gvmj
vulncheck.comvulncheck.com/advisories/openwrt-luci-app-bmx7-path-traversal-via-bmx7-info

Frequently asked

questions

Yes. Any attacker who can reach the OpenWrt web interface exposing the bmx7-info CGI script can attempt to exploit the path traversal without prior authentication.

The attacker needs only network access to the device's LuCI HTTP/HTTPS interface. No valid credentials are required to trigger the vulnerable CGI script.

Constrain all file operations to a well-defined base directory by normalizing paths, rejecting any input that attempts to traverse upward, and preferably mapping user parameters to a controlled set of filenames rather than using them directly in path construction.

Treat all client-supplied path components as untrusted, enforce strict directory boundaries in file-handling code, adopt secure coding guidelines for filesystem access, and integrate static analysis and security review focused on path usage into the development lifecycle.

Find out what's already
exploitable in your codebase.