CVE-2023-22736

CVE-2023-22736 is a high-severity missing authorization vulnerability in github.com/argoproj/argo-cd/v2 (go), affecting versions >= 2.5.0-rc1, < 2.5.8. It is fixed in 2.5.8, 2.6.0-rc5.

Summary

Description of exploit

Reconciled Application namespaces are specified as a comma-delimited list of glob patterns. When sharding is enabled on the Application controller, it does not enforce that list of patterns when reconciling Applications. For example, if Application namespaces are configured to be argocd-*, the Application controller may reconcile an Application installed in a namespace called other, even though it does not start with argocd-.

Reconciliation of the out-of-bounds Application is only triggered when the Application is updated, so the attacker must be able to cause an update operation on the Application resource.

Limitations

This bug only applies to users who have explicitly enabled the "apps-in-any-namespace" feature by setting application.namespaces in the argocd-cmd-params-cm ConfigMap or otherwise setting the --application-namespaces flags on the Application controller and API server components. The apps-in-any-namespace feature is in beta as of this Security Advisory's publish date.

The bug is also limited to Argo CD instances where sharding is enabled by increasing the replicas count for the Application controller.

Finally, the AppProjects' sourceNamespaces field acts as a secondary check against this exploit. To cause reconciliation of an Application in an out-of-bounds namespace, an AppProject must be available which permits Applications in the out-of-bounds namespace.

Workarounds

Running only one replica of the Application controller will prevent exploitation of this bug.

Making sure all AppProjects' sourceNamespaces are restricted within the confines of the configured Application namespaces will also prevent exploitation of this bug.

Credits

Thanks to ChangZhuo Chen (@czchen) for finding the issue and for contributing the fix!

References

For more information

Impact

All Argo CD versions starting with 2.5.0-rc1 are vulnerable to an authorization bypass bug which allows a malicious Argo CD user to deploy Applications outside the configured allowed namespaces.

The application does not perform an authorization check before performing a sensitive operation. Typical impact: unauthorized access to restricted functionality or data.

CVE-2023-22736 has a CVSS score of 8.5 (High). The vector is network-reachable, low privileges required, and no user interaction. A CVSS score reflects the worst-case severity of the vulnerability, not your specific exposure. Whether this affects your application depends on whether the vulnerable code is present and reachable in your environment. A fixed version is available (2.5.8, 2.6.0-rc5); upgrading removes the vulnerable code path.

Affected versions

github.com/argoproj/argo-cd/v2 (>= 2.5.0-rc1, < 2.5.8) github.com/argoproj/argo-cd/v2 (= 2.6.0-rc4)

Security releases

github.com/argoproj/argo-cd/v2 → 2.5.8 (go) github.com/argoproj/argo-cd/v2 → 2.6.0-rc5 (go)

Kodem intelligence

Severity tells you how bad this could be in the worst case. It does not tell you whether you are exposed. Exploitability and impact are functions of runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A vulnerable package can sit in your dependency tree and never run.

Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter. Kodem's runtime-powered SCA identifies whether this CVE is reachable in your applications.

See it in your environment

Remediation advice

A patch for this vulnerability has been released in the following Argo CD versions:

  • v2.5.8
  • v2.6.0-rc5

Frequently Asked Questions

  1. What is CVE-2023-22736? CVE-2023-22736 is a high-severity missing authorization vulnerability in github.com/argoproj/argo-cd/v2 (go), affecting versions >= 2.5.0-rc1, < 2.5.8. It is fixed in 2.5.8, 2.6.0-rc5. The application does not perform an authorization check before performing a sensitive operation.
  2. How severe is CVE-2023-22736? CVE-2023-22736 has a CVSS score of 8.5 (High). This score reflects the worst-case severity of the vulnerability, not your specific exposure. Whether it represents real risk in your environment depends on whether the vulnerable code is present and reachable.
  3. Which versions of github.com/argoproj/argo-cd/v2 are affected by CVE-2023-22736? github.com/argoproj/argo-cd/v2 (go) versions >= 2.5.0-rc1, < 2.5.8 is affected.
  4. Is there a fix for CVE-2023-22736? Yes. CVE-2023-22736 is fixed in 2.5.8, 2.6.0-rc5. Upgrade to this version or later.
  5. Is CVE-2023-22736 exploitable, and should I be worried? Whether CVE-2023-22736 is exploitable in your environment depends on whether the vulnerable code is present and reachable. A CVSS score is a worst-case rating; it does not account for your specific deployment, configuration, or usage patterns. Kodem, an Intelligent Application Security platform, uses runtime intelligence to show which vulnerabilities actually execute in production, so you can focus on the ones that represent real risk. Get a demo
  6. What actually determines whether CVE-2023-22736 is exploitable, and how bad it is? Exploitability and impact are not fixed properties of a CVE. They depend on runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A high CVSS score on a dependency that never runs is not the same as real risk. Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter.
  7. How do I fix CVE-2023-22736?
    • Upgrade github.com/argoproj/argo-cd/v2 to 2.5.8 or later
    • Upgrade github.com/argoproj/argo-cd/v2 to 2.6.0-rc5 or later

Other vulnerabilities in github.com/argoproj/argo-cd/v2

Stop the waste.
Protect your environment with Kodem.