High
Security advisory
An attacker can place a crafted JSON config file into the project folder pointing to a custom executable. VScode-bazel allows the workspace path to lint *.bzl files to be set via this config file. As such the attacker is able to execute any executable on the system through vscode-bazel. We recommend upgrading to version 0.4.1 or above.
- Products
- Not specified
- Affected versions
- Not specified
- Fixed versions
- Not specified
- CVEs
- CVE-2021-22539
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 31 Oct 2026, 11:14 UTC · Revision 1
Source evidence
An attacker can place a crafted JSON config file into the project folder pointing to a custom executable. VScode-bazel allows the workspace path to lint *.bzl files to be set via this config file. As such the attacker is able to execute any executable on the system through vscode-bazel. We recommend upgrading to version 0.4.1 or above.
osv:CVE-2021-22539
Complete source record
{
"id": "7a0467acc76b74437aa6a02cffab36ddbdf290a3aa09fb91b7b0041176f27f7c",
"url": "https://osv.dev/vulnerability/CVE-2021-22539",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "CVE-2021-22539",
"summary": "An attacker can place a crafted JSON config file into the project folder pointing to a custom executable. VScode-bazel allows the workspace path to lint *.bzl files to be set via this config file. As such the attacker is able to execute any executable on the system through vscode-bazel. We recommend upgrading to version 0.4.1 or above.",
"evidence": "osv:CVE-2021-22539",
"products": [],
"severity": "high",
"structured": {
"id": "CVE-2021-22539",
"aliases": [
"CVE-2021-22539",
"GHSA-2rcw-j8x4-hgcv"
],
"metrics": [
{
"type": "CVSS_V3",
"score": "CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H"
}
],
"affected": [
{
"ranges": [
{
"repo": "https://github.com/bazel-contrib/vscode-bazel",
"type": "GIT",
"events": [
{
"introduced": "5f864f7082a39e80b71208bee8852546a1d9dafb"
},
{
"fixed": "d268ed208a03364fecd45bf8e07a35b7408b3b2c"
}
],
"database_specific": {
"extracted_events": [
{
"cpe": "cpe:2.3:a:google:bazel:*:*:*:*:*:visual_studio:*:*",
"range": [
{
"introduced": "0.1.0"
},
{
"fixed": "0.4.1"
}
],
"source": "CPE_RANGE"
}
]
}
}
],
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2021-22539.json"
}
}
],
"modified": "2026-10-20T10:53:36.711136647Z",
"provider": "osv",
"references": [
"https://github.com/bazelbuild/vscode-bazel/security/advisories/GHSA-2rcw-j8x4-hgcv",
"https://github.com/bazelbuild/vscode-bazel-ghsa-2rcw-j8x4-hgcv/pull/1"
],
"provider_metadata": {}
},
"related_cves": [
{
"value": "CVE-2021-22539",
"evidence": "/id"
}
],
"security_relevant": true,
"severity_evidence": "/severity/0/score"
},
"source_id": "core-osv",
"document_id": 384438,
"published_at": "2021-04-16T11:15:12.637+00:00"
}