CVE-2025-62878: Github.com/rancher/local path provisioner Path Traversal Vulnerability

CRITICAL
Advisory Identifier: GHSA-jr3w-9vfr-c746
CVSS 9.9
CWE-23
Published
Advisory Summary

CVE-2025-62878 is a CRITICAL (CVSS 9.9) path traversal vulnerability (CWE-23: Relative Path Traversal) affecting Github.com/rancher/local path provisioner libraries in the Go ecosystem. The issue involves local path provisioner vulnerable to path traversal via parameters.pathpattern. Remediation is available by upgrading affected packages to version 0.0.34.

CVE-2025-62878 at a Glance

CVE Identifier CVE-2025-62878
GHSA Identifier GHSA-jr3w-9vfr-c746
Severity CRITICAL
CVSS v3.1 Base Score 9.9
CWE Classification CWE-23: Relative Path Traversal
Affected Product Github.com/rancher/local path provisioner
Package Ecosystem Go
Published Date
Last Updated

Security Impact

CVSS: 9.9

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required Low (PR:L)
User Interaction None (UI:N)
Scope Changed (S:C)
Confidentiality High (C:H)
Integrity High (I:H)
Availability High (A:H)

How to Fix CVE-2025-62878

To remediate this vulnerability, upgrade all affected Github.com/rancher/local path provisioner dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

github.com/rancher/local-path-provisioner fixed: 0.0.34
Upgrade github.com/rancher/local-path-provisioner to 0.0.34
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for github.com/rancher/local-path-provisioner

How to Check if You Are Affected

To determine whether your application is affected by CVE-2025-62878, inspect your project dependencies for Github.com/rancher/local path provisioner:

inspect dependencies for github.com/rancher/local-path-provisioner

Analyze the terminal output to locate any version of Github.com/rancher/local path provisioner in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.0.34), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-23: Relative Path Traversal, where the product uses external input to construct a pathname that should be within a restricted directory, but it does not properly neutralize sequences such as ".." that can resolve to a location that is outside of that directory. In Github.com/rancher/local path provisioner, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### Impact A malicious user can manipulate the [parameters.pathPattern](https://github.com/rancher/local-path-provisioner/blob/d4f71b4b03a321e9f54be00808e9de42b8bfd35a/provisioner.go#L381) to create PersistentVolumes in arbitrary locations on the host node, potentially overwriting sensitive files or gaining access to unintended directories. Example: ``` apiVersion: storage.k8s.io/v1 kind: StorageClass metadata: annotations: kubectl.kubernetes.io/last-applied-configuration: > {"apiVersion":"storage.k8s.io/v1","kind":"StorageClass","metadata":{"annotations":{},"name":"local-path"},"provisioner":"rancher.io/local-path","reclaimPolicy":"Delete","volumeBindingMode":"WaitForFirstConsumer"} storageclass.kubernetes.io/is-default-class: 'true' name: local-path provisioner: rancher.io/local-path reclaimPolicy: Delete parameters: pathPattern: "{{ .PVC.Namespace }}/{{ .PVC.Name }}/../../../../../etc/new-dir" volumeBindingMode: WaitForFirstConsumer Results in the PersistentVolume to target /etc/new-dir: ``` This produces a PersistentVolume that points to `/etc/new-dir`, instead of a path under the configured base directory. Expected Behavior: - Paths generated from pathPattern should always resolve under the configured base path. - Relative path elements (e.g., ..) should be normalized or rejected. ### Patches This vulnerability is addressed by validating and normalizing the `parameters.pathPattern` to ensure that generated PersistentVolume paths always resolve under the configured base directory. Any path traversal attempts using relative path elements are rejected, preventing PersistentVolumes from being created in arbitrary locations on the host node. Previously, a malicious user could manipulate `pathPattern` to escape the base path and create volumes pointing to sensitive or unintended directories (for example, `/etc`), potentially overwriting host files or gaining unauthorized access. With this fix, path patterns that resolve outside of the base directory are denied, and only safe, normalized paths under the configured base path are allowed. Patched versions of local-path-provisioner include releases v0.0.34 (and later). No patches are provided for earlier releases, as they do not include the necessary path validation and normalization logic. ### Workarounds There are no workarounds for this issue. Users must upgrade to a patched version of local-path-provisioner to fully mitigate the vulnerability. ### References There are any questions or comments about this advisory: - Contact the [SUSE Rancher Security team](https://github.com/rancher/rancher/security/policy) for security related inquiries. - Open an issue in the [Rancher](https://github.com/rancher/rancher/issues/new/choose) repository.

CVE-2025-62878 Affected Github.com/rancher/local path provisioner Versions

1 component(s)
Fixed Versions:
0.0.34
Product / Package Ecosystem Affected Versions Fixed Version
github.com/rancher/local-path-provisioner
Go
< 0.0.34
0.0.34

References

Frequently Asked Questions

What is CVE-2025-62878?
CVE-2025-62878 is a security vulnerability in Github.com/rancher/local path provisioner involving Local Path Provisioner vulnerable to Path Traversal via parameters.pathPattern under CWE-23: Relative Path Traversal.
Which Github.com/rancher/local path provisioner versions are affected?
Affected versions include releases prior to 0.0.34 across affected packages: github.com/rancher/local-path-provisioner.
What version fixes CVE-2025-62878?
Upgrading to 0.0.34 (or the latest patched release for your respective branch) resolves the vulnerability.
Is github.com/rancher/local-path-provisioner affected?
Yes, github.com/rancher/local-path-provisioner is affected in releases prior to 0.0.34. Upgrade your dependency to 0.0.34 or later.
What is the CVSS score of CVE-2025-62878?
CVE-2025-62878 has a CVSS v3.1 base score of 9.9 (CRITICAL) with vector string CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H.
What CWE is associated with CVE-2025-62878?
CVE-2025-62878 is classified under CWE-23: Relative Path Traversal (The product uses external input to construct a pathname that should be within a restricted directory, but it does not properly neutralize sequences such as ".." that can resolve to a location that is outside of that directory.).
How can I check Go dependencies for CVE-2025-62878?
Run the dependency tree command: 'inspect dependencies for github.com/rancher/local-path-provisioner'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-jr3w-9vfr-c746",
  "modified" : "2026-02-27T20:41:26Z",
  "published" : "2026-02-04T20:17:42Z",
  "aliases" : [ "CVE-2025-62878" ],
  "summary" : "Local Path Provisioner vulnerable to Path Traversal via parameters.pathPattern",
  "details" : "### Impact\n\nA malicious user can manipulate the [parameters.pathPattern](https://github.com/rancher/local-path-provisioner/blob/d4f71b4b03a321e9f54be00808e9de42b8bfd35a/provisioner.go#L381) to create PersistentVolumes in arbitrary locations on the host node, potentially overwriting sensitive files or gaining access to unintended directories.\n\nExample:\n```\napiVersion: storage.k8s.io/v1\nkind: StorageClass\nmetadata:\n  annotations:\n    kubectl.kubernetes.io/last-applied-configuration: >\n      {\"apiVersion\":\"storage.k8s.io/v1\",\"kind\":\"StorageClass\",\"metadata\":{\"annotations\":{},\"name\":\"local-path\"},\"provisioner\":\"rancher.io/local-path\",\"reclaimPolicy\":\"Delete\",\"volumeBindingMode\":\"WaitForFirstConsumer\"}\n    storageclass.kubernetes.io/is-default-class: 'true'\n  name: local-path\nprovisioner: rancher.io/local-path\nreclaimPolicy: Delete\nparameters:\n  pathPattern: \"{{ .PVC.Namespace }}/{{ .PVC.Name }}/../../../../../etc/new-dir\"\nvolumeBindingMode: WaitForFirstConsumer\nResults in the PersistentVolume to target /etc/new-dir:\n```\nThis produces a PersistentVolume that points to `/etc/new-dir`, instead of a path under the configured base directory.\n\nExpected Behavior:\n- Paths generated from pathPattern should always resolve under the configured base path.\n- Relative path elements (e.g., ..) should be normalized or rejected.\n\n\n### Patches\n\nThis vulnerability is addressed by validating and normalizing the `parameters.pathPattern` to ensure that generated PersistentVolume paths always resolve under the configured base directory. Any path traversal attempts using relative path elements are rejected, preventing PersistentVolumes from being created in arbitrary locations on the host node.\n\nPreviously, a malicious user could manipulate `pathPattern` to escape the base path and create volumes pointing to sensitive or unintended directories (for example, `/etc`), potentially overwriting host files or gaining unauthorized access.\n\nWith this fix, path patterns that resolve outside of the base directory are denied, and only safe, normalized paths under the configured base path are allowed.\n\nPatched versions of local-path-provisioner include releases v0.0.34 (and later).\n\nNo patches are provided for earlier releases, as they do not include the necessary path validation and normalization logic.\n\n### Workarounds\n\nThere are no workarounds for this issue. Users must upgrade to a patched version of local-path-provisioner to fully mitigate the vulnerability.\n\n### References\n\nThere are any questions or comments about this advisory:\n\n- Contact the [SUSE Rancher Security team](https://github.com/rancher/rancher/security/policy) for security related inquiries.\n- Open an issue in the [Rancher](https://github.com/rancher/rancher/issues/new/choose) repository.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/rancher/local-path-provisioner"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "0.0.34"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/rancher/local-path-provisioner/security/advisories/GHSA-jr3w-9vfr-c746"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2025-62878"
  }, {
    "type" : "WEB",
    "url" : "https://bugzilla.suse.com/show_bug.cgi?id=CVE-2025-62878"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/rancher/local-path-provisioner"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/rancher/local-path-provisioner/blob/d4f71b4b03a321e9f54be00808e9de42b8bfd35a/provisioner.go#L381"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-23" ],
    "severity" : "CRITICAL",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-02-04T20:17:42Z",
    "nvd_published_at" : "2026-02-25T11:16:01Z"
  }
}