Register for the AI for Security Summit: Join Figma, Perplexity & Wiz

CVE-2021-22539
NixOS vulnerability analysis and mitigation

Overview

A critical vulnerability (CVE-2021-22539) was discovered in vscode-bazel versions 0.1.0 through 0.4.0. The vulnerability allows attackers to execute arbitrary code by placing a crafted JSON config file into the project folder that points to a custom executable. This security flaw was discovered and reported by Ry0taK, and was patched in version 0.4.1 (GitHub Advisory).

Technical details

The vulnerability stems from improper access control in the workspace settings, specifically related to the 'bazel.buildifierExecutable' setting. This setting can be modified by simply placing a malicious JSON configuration file in a folder, allowing attackers to specify arbitrary executable paths for linting *.bzl files. The vulnerability has been assigned a CVSS score of 8.3 (High) with the vector string CVSS:3.1/AV:L/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:H, indicating local attack vector, low attack complexity, low privileges required, and high impact on confidentiality, integrity, and availability (GitHub Advisory).

Impact

The vulnerability can lead to arbitrary code execution on the affected system. When exploited, an attacker can execute any program of their choice through the buildifier executable path setting, potentially compromising the system's confidentiality, integrity, and availability (GitHub Advisory).

Exploitability

The vulnerability requires local access to the system and the ability to place files in the project directory. User interaction is required as the exploitation occurs when linting *.bzl files. The attack complexity is considered low, making it relatively straightforward to exploit once the prerequisites are met (GitHub Advisory).

Mitigation and workarounds

The vulnerability has been patched in vscode-bazel version 0.4.1. Users are strongly recommended to upgrade to version 0.4.1 or later to address this security issue. No alternative workarounds have been provided (GitHub Advisory).

Additional resources


SourceThis report was generated using AI

Related NixOS vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2026-91782LOW1.9
  • NixOS logoNixOS
  • binutils
NoYesSep 15, 2026
CVE-2026-91781LOW1.9
  • NixOS logoNixOS
  • binutils
NoYesSep 15, 2026
CVE-2026-91780LOW1.9
  • NixOS logoNixOS
  • binutils
NoNoSep 15, 2026
CVE-2026-91779LOW1.9
  • NixOS logoNixOS
  • binutils
NoNoSep 15, 2026
CVE-2026-90831LOW1.9
  • NixOS logoNixOS
  • seal-binutils
NoYesSep 14, 2026

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management