CVE-2022-24348: Github.com/argoproj/argo cd/v2 Path Traversal Vulnerability

HIGH
Advisory Identifier: GHSA-63qx-x74g-jcr7
CVSS 7.7
CWE-200 CWE-22
Published
Advisory Summary

CVE-2022-24348 is a HIGH (CVSS 7.7) path traversal vulnerability (CWE-200: Exposure of Sensitive Information to an Unauthorized Actor) affecting Github.com/argoproj/argo cd/v2 libraries in the Go ecosystem. The issue involves path traversal and dereference of symlinks in argo cd. Remediation is available by upgrading affected packages to version 2.1.9, 2.2.4.

CVE-2022-24348 at a Glance

CVE Identifier CVE-2022-24348
GHSA Identifier GHSA-63qx-x74g-jcr7
Severity HIGH
CVSS v3.1 Base Score 7.7
CWE Classification CWE-200: Exposure of Sensitive Information to an Unauthorized Actor
Affected Product Github.com/argoproj/argo cd/v2
Package Ecosystem Go
Published Date
Last Updated

Security Impact

CVSS: 7.7

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:N/A:N).

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 None (I:N)
Availability None (A:N)

How to Fix CVE-2022-24348

To remediate this vulnerability, upgrade all affected Github.com/argoproj/argo cd/v2 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/argoproj/argo-cd/v2 fixed: 2.1.9
Upgrade github.com/argoproj/argo-cd/v2 to 2.1.9
github.com/argoproj/argo-cd/v2 fixed: 2.2.4
Upgrade github.com/argoproj/argo-cd/v2 to 2.2.4
github.com/argoproj/argo-cd fixed: 2.1.9
Upgrade github.com/argoproj/argo-cd to 2.1.9
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/argoproj/argo-cd/v2

How to Check if You Are Affected

To determine whether your application is affected by CVE-2022-24348, inspect your project dependencies for Github.com/argoproj/argo cd/v2:

inspect dependencies for github.com/argoproj/argo-cd/v2

Analyze the terminal output to locate any version of Github.com/argoproj/argo cd/v2 in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.1.9), 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-200: Exposure of Sensitive Information to an Unauthorized Actor, where the product exposes sensitive information to an actor that is not explicitly authorized to have access to that information. In Github.com/argoproj/argo cd/v2, 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 All versions of Argo CD are vulnerable to a path traversal bug that allows to pass arbitrary values files to be consumed by Helm charts. Additionally, it is possible to craft special Helm chart packages containing value files that are actually symbolic links, pointing to arbitrary files outside the repository's root directory. If an attacker with permissions to create or update Applications knows or can guess the full path to a file containing valid YAML, they can create a malicious Helm chart to consume that YAML as values files, thereby gaining access to data they would otherwise have no access to. The impact can especially become critical in environments that make use of encrypted value files (e.g. using plugins with git-crypt or SOPS) containing sensitive or confidential data, and decrypt these secrets to disk before rendering the Helm chart. Also, because any error message from `helm template` is passed back to the user, and these error messages are quite verbose, enumeration of files on the repository server's file system is possible. ### Patches A patch for this vulnerability has been released in the following Argo CD versions: * v2.3.0 * v2.2.4 * v2.1.9 We urge users of Argo CD to update their installation to one of the fixed versions as listed above. ### Workarounds No workaround for this issue. ### References * https://apiiro.com/blog/malicious-kubernetes-helm-charts-can-be-used-to-steal-sensitive-information-from-argo-cd-deployments * https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2022-24348 ### For more information * Open an issue in [the Argo CD issue tracker](https://github.com/argoproj/argo-cd/issues) or [discussions](https://github.com/argoproj/argo-cd/discussions) * Join us on [Slack](https://argoproj.github.io/community/join-slack) in channel `#argo-cd` ### Credits The path traversal vulnerability was discovered and reported by Moshe Zioni, VP Security Research, [Apiiro](https://www.apiiro.com). During the development of a fix for the path traversal vulnerability, the Argo CD team discovered the related issue with symbolic links. The Argo CD team would like to thank Moshe Zioni for the responsible disclosure, and the constructive discussions during handling this issue!

CVE-2022-24348 Affected Github.com/argoproj/argo cd/v2 Versions

3 component(s)
Fixed Versions:
2.1.92.2.4
Product / Package Ecosystem Affected Versions Fixed Version
github.com/argoproj/argo-cd/v2
Go
< 2.1.9
2.1.9
github.com/argoproj/argo-cd/v2
Go
≥ 2.2.0
< 2.2.4
2.2.4
github.com/argoproj/argo-cd
Go
< 2.1.9
2.1.9

References

Frequently Asked Questions

What is CVE-2022-24348?
CVE-2022-24348 is a security vulnerability in Github.com/argoproj/argo cd/v2 involving Path traversal and dereference of symlinks in Argo CD under CWE-200: Exposure of Sensitive Information to an Unauthorized Actor.
Which Github.com/argoproj/argo cd/v2 versions are affected?
Affected versions include releases prior to 2.1.9, 2.2.4 across affected packages: github.com/argoproj/argo-cd/v2, github.com/argoproj/argo-cd.
What version fixes CVE-2022-24348?
Upgrading to 2.1.9, 2.2.4 (or the latest patched release for your respective branch) resolves the vulnerability.
Is github.com/argoproj/argo-cd/v2 affected?
Yes, github.com/argoproj/argo-cd/v2 is affected in releases prior to 2.1.9, 2.2.4. Upgrade your dependency to 2.1.9, 2.2.4 or later.
Is github.com/argoproj/argo-cd affected?
Yes, github.com/argoproj/argo-cd is affected in releases prior to 2.1.9. Upgrade your dependency to 2.1.9 or later.
What is the CVSS score of CVE-2022-24348?
CVE-2022-24348 has a CVSS v3.1 base score of 7.7 (HIGH) with vector string CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:N/A:N.
What CWE is associated with CVE-2022-24348?
CVE-2022-24348 is classified under CWE-200: Exposure of Sensitive Information to an Unauthorized Actor (The product exposes sensitive information to an actor that is not explicitly authorized to have access to that information.).
How can I check Go dependencies for CVE-2022-24348?
Run the dependency tree command: 'inspect dependencies for github.com/argoproj/argo-cd/v2'. 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-63qx-x74g-jcr7",
  "modified" : "2024-08-07T19:46:23Z",
  "published" : "2022-02-07T19:06:18Z",
  "aliases" : [ "CVE-2022-24348" ],
  "summary" : "Path traversal and dereference of symlinks in Argo CD",
  "details" : "### Impact\n\nAll versions of Argo CD are vulnerable to a path traversal bug that allows to pass arbitrary values files to be consumed by Helm charts. \n\nAdditionally, it is possible to craft special Helm chart packages containing value files that are actually symbolic links, pointing to arbitrary files outside the repository's root directory.\n\nIf an attacker with permissions to create or update Applications knows or can guess the full path to a file containing valid YAML, they can create a malicious Helm chart to consume that YAML as values files, thereby gaining access to data they would otherwise have no access to. \n\nThe impact can especially become critical in environments that make use of encrypted value files (e.g. using plugins with git-crypt or SOPS) containing sensitive or confidential data, and decrypt these secrets to disk before rendering the Helm chart.\n\nAlso, because any error message from `helm template` is passed back to the user, and these error messages are quite verbose, enumeration of files on the repository server's file system is possible.\n\n### Patches\n\nA patch for this vulnerability has been released in the following Argo CD versions:\n\n* v2.3.0\n* v2.2.4\n* v2.1.9\n\nWe urge users of Argo CD to update their installation to one of the fixed versions as listed above.\n\n### Workarounds\n\nNo workaround for this issue.\n\n### References\n\n* https://apiiro.com/blog/malicious-kubernetes-helm-charts-can-be-used-to-steal-sensitive-information-from-argo-cd-deployments\n* https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2022-24348\n\n### For more information\n\n* Open an issue in [the Argo CD issue tracker](https://github.com/argoproj/argo-cd/issues) or [discussions](https://github.com/argoproj/argo-cd/discussions)\n* Join us on [Slack](https://argoproj.github.io/community/join-slack) in channel `#argo-cd`\n\n### Credits\n\nThe path traversal vulnerability was discovered and reported by Moshe Zioni, VP Security Research, [Apiiro](https://www.apiiro.com). \n\nDuring the development of a fix for the path traversal vulnerability, the Argo CD team discovered the related issue with symbolic links.\n\nThe Argo CD team would like to thank Moshe Zioni for the responsible disclosure, and the constructive discussions during handling this issue!\n",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:N/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/argoproj/argo-cd/v2"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "2.1.9"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/argoproj/argo-cd/v2"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "2.2.0"
      }, {
        "fixed" : "2.2.4"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/argoproj/argo-cd"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "2.1.9"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/argoproj/argo-cd/security/advisories/GHSA-63qx-x74g-jcr7"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2022-24348"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/argoproj/argo-cd/commit/78c2084f0febd159039ff785ddc2bd4ba1cecf88"
  }, {
    "type" : "WEB",
    "url" : "https://apiiro.com/blog/malicious-kubernetes-helm-charts-can-be-used-to-steal-sensitive-information-from-argo-cd-deployments"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/argoproj/argo-cd"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/argoproj/argo-cd/releases/tag/v2.1.9"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/argoproj/argo-cd/releases/tag/v2.2.4"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-200", "CWE-22" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2022-02-03T22:53:47Z",
    "nvd_published_at" : "2022-02-04T21:15:00Z"
  }
}