/

CVE-2026-65919

Severity:

HIGH RISK

(7.5)

Path Traversal (CWE-22) in Meshery File APIs

CVE-2026-65919

Deferred

Vulnerability type

Category:

Path Traversal / Arbitrary File Read

CWE:

CWE-22

Impact:

Arbitrary File Read on Host Filesystem

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

Meshery exposes unauthenticated file viewing and download endpoints that accept user-supplied paths without proper validation.

By passing absolute or traversal-based paths, an attacker can read arbitrary files from the host filesystem, making deployments with exposed APIs highly risky.

Affected context

This vulnerability occurs in Meshery instances that:

  • Expose the /api/system/fileView and /api/system/fileDownload endpoints
  • Accept user-provided file path parameters and forward them directly to filesystem APIs
  • Run with permissions that allow access to sensitive files on the host or container filesystem

It is most concerning when Meshery is reachable over a network where untrusted users can invoke these endpoints.

Exploit preconditions

  • Attack surface: HTTP access to Meshery's /api/system/fileView and /api/system/fileDownload endpoints
  • Required access: None; the endpoints are unauthenticated in affected versions
  • Trigger point: Supplying crafted file path values (absolute paths or ../ traversal) in the request parameters
  • Why exploitation is possible: The application passes user-controlled paths directly to os.Open without normalization, restriction to a safe base directory, or validation, enabling traversal outside any intended directory scope.

Why this happens

The underlying issue is a classic path traversal vulnerability mapped to CWE-22: Improper Limitation of a Pathname to a Restricted Directory.

Meshery's file handling logic treats user input as a trusted filesystem path and forwards it directly to os.Open without enforcing a bounded root directory, stripping traversal sequences, or validating against an allowlist.

Abstractly, this pattern occurs whenever a web-facing parameter is used as a direct argument to file access APIs without constraining the path to a controlled, application-owned directory.

Potential impact

  • An attacker may read configuration files containing secrets or API keys.
  • An attacker could access operating system files that reveal environment details, user accounts, or service configurations.
  • An attacker may obtain logs or internal data that aid further attacks or lateral movement.
  • An attacker could read source code and templates, increasing the likelihood of discovering additional vulnerabilities.
  • In certain deployments, an attacker can access files belonging to other applications sharing the same host.

General mitigation guidance

Effective mitigation typically focuses on constraining file access to a well-defined, safe directory and treating all path input as untrusted.

Common defensive patterns include:

  • Resolving user-supplied paths against a dedicated base directory and rejecting requests that escape this directory after normalization.
  • Implementing strict validation or allowlisting for accessible files or directories, rather than accepting arbitrary paths.
  • Avoiding direct use of raw user input in filesystem APIs; use abstraction layers that enforce path restrictions by default.
  • Running the application with least-privilege filesystem permissions so that even if a flaw exists, sensitive system files are not readable.
  • Logging rejected path access attempts and monitoring for anomalous usage of file-related endpoints.

How teams detect issues like this

High-level detection approaches include:

  • Static analysis rules that flag direct use of user-controlled variables in file APIs like os.Open, especially in HTTP handlers.
  • Code review checklists that call out path handling logic and require verification of normalization and directory bounding.
  • Security policies that mandate the use of centralized file-access utilities which enforce safe base paths and block traversal.
  • Runtime monitoring for suspicious access patterns, such as repeated requests containing ../ sequences or absolute paths to system directories.
  • Use of automated application security testing tools that generate path traversal test cases against file-view and download endpoints.

Sources

SourceLink
github.comgithub.com/meshery/meshery/commit/ea83a26cb090b13be36c07cf24a99f8c637cc765
github.comgithub.com/meshery/meshery/issues/20076
github.comgithub.com/meshery/meshery/pull/20133
github.comgithub.com/meshery/meshery/releases/tag/v1.0.57
vulncheck.comvulncheck.com/advisories/meshery-unauthenticated-arbitrary-file-read-via-fileview-and-filedownload

Frequently asked

questions

Yes. Any user with network access to the Meshery HTTP API can issue requests to the affected file endpoints and attempt to read files, as no authentication is required in vulnerable versions.

The attacker only needs the ability to reach the /api/system/fileView or /api/system/fileDownload endpoints over the network. No valid credentials or prior compromise are required.

Constrain all file access to a dedicated, application-owned directory; normalize requested paths; reject any path that attempts traversal outside this directory; and avoid passing raw user input directly into filesystem APIs. Additionally, enforce authentication and authorization on file-related endpoints.

Establish secure coding standards for path handling, use vetted file-access helpers that enforce directory boundaries, include path traversal checks in static analysis and code review, and require authentication plus least-privilege access for any endpoint that interacts with the filesystem.

Find out what's already
exploitable in your codebase.