← Übersicht Argo Workflows / Rollouts / Events

Argo Workflows Cloud Artifact Slip (Path Traversal Variant)

GHSA-vm9v-p987-xm32

Hoch · CVSS 8.8 Netzwerk · mit Login Fix verfügbar

Veröffentlicht
18.09.2026 10:14
Zuletzt geändert
18.09.2026
EPSS (30 Tage)
unbekannt
CVSS-Vektor
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

Beschreibung

Originaltext der Quelle, nicht übersetzt.

### Advisory Details **Title**: Argo Workflows Cloud Artifact Slip (Path Traversal Variant) **Description**: ### Summary A critical path traversal vulnerability exists in the artifact materialization process of Argo Workflows when handling directory artifacts stored in cloud object storage (S3, GCS, Azure Blob). The vulnerability occurs when a malicious object key contains directory traversal components (e.g., `../`). Since the `argoexec` artifact drivers do not securely validate or sanitize the cloud-provided object keys, this allows an attacker to escape the designated executor workspace. An attacker with write access to the referenced external S3 bucket (or capable of setting a malicious bucket) can leverage this flaw to perform arbitrary file overwrites inside the workflow execution environment. This can lead to arbitrary remote code execution (RCE) and privilege escalation inside the Pod. ### Details The `GetDirectory` and `DownloadDirectory` functions in Argo Workflows artifact drivers (such as S3, Azure Blob, and GCS) fetch all objects under a specific bucket prefix and write them to a local workspace path inside the executor pod. In the vulnerable implementation (e.g., in `workflow/artifacts/s3/s3.go`), the drivers compute the local destination path by using `strings.TrimPrefix` to remove the directory prefix and then directly append the remaining key to the target download directory using `filepath.Join()`. ```go // From workflow/artifacts/s3/s3.go for _, objKey := range keys { relKeyPath := strings.TrimPrefix(objKey, keyPrefix) localPath := filepath.Join(path, relKeyPath) // ... file is subsequently written to localPath } ``` Because `filepath.Join` resolves `../` sequences across the combined path rather than restricting them to the base directory, a maliciously crafted external object key can escape the designated workspace. This results in an arbitrary file write when the object is subsequently downloaded. The vulnerability mirrors the classic "Zip Slip" pattern, but exploits the unvalidated path components natively provided by Cloud Storage APIs instead of a compression archive. ### PoC #### Prerequisites 1. A workflow utilizes an `input` artifact defined as a directory (`S3`, `GCS`, `Azure`, etc.). 2. The attacker has write access to the referenced cloud object storage bucket, or they provide a malicious artifact source. #### Reproduction Steps 1. Download the PoC exploit script from: [poc_exploit.py](https://gist.github.com/secret_gist_url_poc_exploit) 2. Download the control normal behavior script from: [control-normal_behavior.py](https://gist.github.com/secret_gist_url_control_normal_behavior) 3. Set up the target environment and start the exploit HTTP server to perform a path traversal overwrite: ```bash python3 poc_exploit.py ``` 4. Run the control experiment script to observe the normal behavior being blocked from path traversal: ```bash python3 control-normal_behavior.py ``` ### Log of Evidence ``` [SUCCESS] Exploit worked! Found pwned.txt with content. ``` ### Patches Fixed in v4.1.4 and v4.0.12. The S3, GCS, Azure and OSS drivers now derive every local path through a shared containment check: the object key, relative to the listed prefix, must resolve inside the download destination, its nearest existing ancestor must not resolve outside the destination through a symlink, and the final path must not already be a symlink. A key that fails any check aborts the download with `illegal object key`. The S3 driver also trims the same normalized prefix it lists under, which previously differed when the configured key had no trailing slash. v3 is not being patched. Users on v3 should upgrade. ### Workarounds Do not consume directory artifacts from buckets or prefixes that untrusted parties can write to. In shared-bucket deployments, note that any workflow author may choose arbitrary output keys. ### Impact This is an Arbitrary File Write vulnerability leading to Remote Code Execution (RCE) and potential privilege escalation within the context of the Argo `wait` or `init` executor container. An attacker who compromises a shared data bucket or is allowed to provide a customized input artifact endpoint can overwrite arbitrary executor binaries, Kubernetes configurations, or dump sensitive service accounts running on the node. ### Affected products - **Ecosystem**: go - **Package name**: argo-workflows - **Affected versions**: v4.1.0 to v4.1.3, v4.0.0 to v4.0.11, and all v3 releases - **Patched versions**: v4.1.4, v4.0.12 ### Severity - **Severity**: High - **Vector string**: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H (8.8). Scope is unchanged: the write lands inside the workflow pod that consumed the artifact. ### Weaknesses - **CWE**: CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal') ### Occurrences | Permalink | Description | | :--- | :--- | | [https://github.com/argoproj/argo-workflows/blob/main/workflow/artifacts/s3/s3.go#L667-L668](https://github.com/argoproj/argo-workflows/blob/main/workflow/artifacts/s3/s3.go#L667-L668) | The vulnerable S3 artifact driver code that trims the prefix and joins it unsafely to the local path. | | [https://github.com/argoproj/argo-workflows/blob/main/workflow/artifacts/azure/azure.go#L218-L219](https://github.com/argoproj/argo-workflows/blob/main/workflow/artifacts/azure/azure.go#L218-L219) | The vulnerable Azure artifact driver code that processes blob objects with unsafe relative paths. | | [https://github.com/argoproj/argo-workflows/blob/main/workflow/artifacts/gcs/gcs.go#L153-L154](https://github.com/argoproj/argo-workflows/blob/main/workflow/artifacts/gcs/gcs.go#L153-L154) | The vulnerable GCS artifact driver code that uses `TrimPrefix` resulting in path traversal during directory download. |

Betroffene Pakete im beobachteten Stack

Gogithub.com/argoproj/argo-workflows/v3kein Fix bekanntGHSA-vm9v-p987-xm32
Gogithub.com/argoproj/argo-workflows/v44.1.0 → 4.1.4GHSA-vm9v-p987-xm32
Gogithub.com/argoproj/argo-workflows/v44.0.0 → 4.0.12GHSA-vm9v-p987-xm32

Empfohlene Prüfung

  1. Feststellen, ob und in welcher Version die betroffenen Pakete in Ihren Systemen, Images und Abhängigkeiten vorkommen.
  2. Wo eine Fix-Version genannt ist: aktualisieren. Wo nicht: Hersteller-Advisory und Referenzen auf Workarounds prüfen.
  3. Erreichbarkeit beachten: Der Angriffsweg (Netzwerk · mit Login) ist aus dem CVSS-Vektor abgeleitet.

Diese Seite sagt nichts darüber, ob Ihre Systeme betroffen sind. Das klärt erst eine Prüfung Ihrer Versionen.