/

CVE-2026-25705

Severity:

HIGH RISK

(8.4)

Path Traversal in compressedEndpoint within Rancher UI

CVE-2026-25705

Awaiting Analysis

Vulnerability type

Category:

Path Traversal / Directory Traversal

CWE:

CWE-35

Impact:

Arbitrary File Write and Potential Remote Code Execution

Severity:

HIGH RISK

(8.4)

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 flaw in the compressedEndpoint field of Rancher UIPlugin deployments allows a malicious Rancher Extension to write files outside its intended directory.

Under certain deployment configurations, this can enable attackers to overwrite Rancher binaries or configuration, tamper with cluster state, or even write to the underlying host filesystem.

Affected context

This vulnerability affects environments using Rancher Extensions, specifically UI plugins deployed via UIPlugin configurations that accept a compressedEndpoint value.

The risk is most pronounced where:

  • Extensions are installed from sources that are not fully trusted, and
  • The Rancher manager has write access to sensitive paths such as its own binary/config directories, /var/lib/rancher/, or hostPath-mounted directories.

The issue surfaces when the plugin deployment process resolves paths derived from compressedEndpoint without enforcing strict directory constraints.

Exploit preconditions

  • Attack surface: Rancher Extensions / UIPlugin deployment APIs or mechanisms.
  • Required access: Ability to register or update a Rancher UI Extension (e.g., manage or influence UIPlugin specs or extension catalog entries).
  • Trigger point: Processing and extraction of the archive or assets referenced by compressedEndpoint during plugin deployment/update.
  • Why exploitation is possible: The compressedEndpoint value is used to construct filesystem paths without proper normalization and enforcement of a fixed base directory, allowing traversal sequences (e.g., ../) to escape the intended location and target arbitrary writable paths.

Why this happens

The core issue is a classic directory traversal pattern where user-controlled path components are concatenated or resolved into filesystem paths without robust sanitization or confinement.

Instead of enforcing a strict, canonicalized base directory for extracted extension assets, the implementation appears to trust the compressedEndpoint value and fails to strip or reject traversal sequences.

This aligns with CWE-35: Path Traversal, where improper validation of paths derived from untrusted input permits read or write access outside the intended directory, turning plugin installation into a vehicle for arbitrary file placement or overwrite.

Potential impact

  • Overwriting Rancher binaries or configuration files, which can lead to:
  • Execution of injected code in the Rancher management plane
  • Persistent compromise of Rancher services
  • Tampering with data under /var/lib/rancher/, potentially:
  • Corrupting or altering cluster state and metadata
  • Impacting cluster lifecycle, node registration, or workloads
  • Writing into host node filesystems via hostPath volumes, which can:
  • Modify host configuration or binaries
  • Facilitate container escape or broader node compromise
  • Providing a foothold to chain with other vulnerabilities or misconfigurations for privilege escalation or lateral movement.

General mitigation guidance

Effective mitigation typically focuses on constraining file system writes and hardening extension trust boundaries:

  • Normalize and canonicalize all paths derived from compressedEndpoint, and verify that the final resolved path remains within a predefined, dedicated extensions directory.
  • Reject any plugin input that contains path traversal indicators (e.g., .., absolute paths, or symbolic link chains that escape the allowed root).
  • Run the Rancher manager and extension processing components with least-privilege filesystem access, avoiding unnecessary write permissions to binary directories, /var/lib/rancher/, or hostPath-mounted locations.
  • Treat extensions as untrusted by default: establish a review and signing process for third-party or custom extensions, and limit who can register or update UIPlugin resources.
  • Consider segregating extension storage into separate volumes with restricted mount options and no direct mapping to hostPath volumes where feasible.

How teams detect issues like this

High-level detection can combine static review of code and runtime controls:

  • Static analysis / code review:
  • Look for any logic that constructs destination paths from extension metadata (including compressedEndpoint) without:
  • Canonicalization (realpath-style checks)
  • Explicit base directory enforcement
  • Flag direct concatenation of user-controlled path segments into open, write, extraction utilities, or archive unpacking routines.
  • Configuration and policy review:
  • Enforce policies that restrict who may install or update Rancher Extensions and UIPlugin resources.
  • Audit cluster configurations for hostPath mounts exposed to components processing extensions, and reduce these where possible.
  • Runtime monitoring:
  • Monitor Rancher manager pods for unexpected write activity to critical paths (binaries, configuration directories, /var/lib/rancher/, and hostPath targets).
  • Use file integrity monitoring (FIM) on Rancher-related directories and sensitive host paths to detect unexpected modifications following extension changes.
  • Automated security scanning tools and CI/CD hooks can be configured to flag directory traversal patterns and risky filesystem operations in extension management code.

Sources

SourceLink
bugzilla.suse.combugzilla.suse.com/show_bug.cgi?id=CVE-2026-25705
github.comgithub.com/rancher/rancher/security/advisories/GHSA-5v3h-x4wf-5c35

Frequently asked

questions

It can be remotely exploitable if an attacker can interact with Rancher's APIs or UI in a way that allows them to create or modify UIPlugin definitions or extension sources. In that case, they may not need local cluster access to trigger the path traversal.

The attacker generally needs the ability to register, modify, or influence Rancher UI Extensions—typically permissions to manage UIPlugin resources or control an extension catalog used by Rancher. Without that capability, exploitation is unlikely.

The safest pattern is to strictly confine all extension-related filesystem operations to a dedicated directory, normalize the final paths, and reject any plugin input that attempts to escape that directory. Coupling this with reduced filesystem privileges for the Rancher manager further limits potential damage.

Adopt a defensive design for all plugin and extension mechanisms: treat all extension metadata as untrusted, enforce canonical path checks, apply least-privilege to filesystem access, require signing or vetting of extensions, and integrate security-focused code review and static analysis rules targeting path usage and archive extraction logic.

Find out what's already
exploitable in your codebase.