CVE-2021-20329 | Specific cstrings input may not be properly validated in the Go Driver

Specific cstrings input may not be properly validated in the MongoDB Go Driver when marshalling Go objects into BSON. A malicious user could use a Go object with specific string to potentially inject additional fields into marshalled documents. This issue affects all MongoDB GO Drivers prior to and including 1.5.0.

Published: 2021-06-10 Last update: 2024-11-21 Assigner: [email protected] Source: [email protected]

Conclusion & alert: CVE-2021-20329 is rated Moderate Risk (47.9/100): CVSS Medium severity, with medium exploitation likelihood (EPSS 0.96%). Mandatory action: Review affected assets and schedule remediation.

Risk is dynamic; we continuously reassess and refresh what is shown on this page as upstream context changes.

Exploit prediction scoring system (EPSS) score for CVE-2021-20329

EPSS lead: Daily EPSS estimates relative likelihood of exploitation; percentile ranks this CVE among scored vulnerabilities (higher = more severe relative rank).

# Date Old EPSS score New EPSS score Delta (New - Old)
1 2026-06-15 0.14% 0.96% +0.82%
2 2026-04-01 0.19% 0.14% -0.05%
3 2026-01-14 0.19%

Full EPSS history (14 records total)

Common vulnerability scoring system (CVSS) metrics for CVE-2021-20329

CVSS metrics for this CVE.

Base score Version Severity Vector Exploitability Impact Score source
6.8 3.1 MEDIUM
CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:N Click to expand
Attack vector (AV:N)
Could be attacked over the internet or any normal routed network—not just someone sitting at the machine.
Attack complexity (AC:H)
Even with access, the exploit needs extra luck, timing, or a fussy environment to actually work.
Privileges required (PR:L)
A normal user session is enough; they don’t have to be admin.
User interaction (UI:N)
Nobody has to click “OK” or open a trap file; it can work without a victim helping.
Scope (S:U)
Damage stays in the same “trust bubble” as the broken component—no big spill into unrelated systems.
Confidentiality (C:H)
Serious risk that confidential data gets exposed in a big way.
Integrity (I:H)
They could widely tamper with or forge data—trust in the data is badly hurt.
Availability (A:N)
Service keeps running; no real outage angle.
1.6 5.2 [email protected]
6.5 3.1 MEDIUM
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N Click to expand
Attack vector (AV:N)
Could be attacked over the internet or any normal routed network—not just someone sitting at the machine.
Attack complexity (AC:L)
Once they can reach the bug, pulling it off is straightforward—no weird race conditions or rare setup.
Privileges required (PR:L)
A normal user session is enough; they don’t have to be admin.
User interaction (UI:N)
Nobody has to click “OK” or open a trap file; it can work without a victim helping.
Scope (S:U)
Damage stays in the same “trust bubble” as the broken component—no big spill into unrelated systems.
Confidentiality (C:N)
Doesn’t really leak secrets in a meaningful way.
Integrity (I:H)
They could widely tamper with or forge data—trust in the data is badly hurt.
Availability (A:N)
Service keeps running; no real outage angle.
2.8 3.6 [email protected]
4.0 2.0 MEDIUM
AV:N/AC:L/Au:S/C:N/I:P/A:N Click to expand
Access vector (AV:N)
Can be exploited remotely over network reachability.
Access complexity (AC:L)
Exploitation conditions are straightforward and predictable.
Authentication (AU:S)
A single authentication is required.
Confidentiality impact (C:N)
No confidentiality impact.
Integrity impact (I:P)
Partial integrity impact.
Availability impact (A:N)
No availability impact.
8.0 2.9 [email protected]

Weakness enumeration for CVE-2021-20329

GitHub Security Advisory for CVE-2021-20329

GHSA-f6mq-5m25-4r72 · Severity: medium · Ecosystem: go — go.mongodb.org/mongo-driver improperly validates cstrings when marshalling Go objects into BSON

OS Trackers for CVE-2021-20329

vendor priority summary link
redhat medium https://access.redhat.com/security/cve/CVE-2021-20329
ubuntu low CVE-2021-20329 low priority: Ubuntu including 1 source packages (mongodb), 16 status rows across 16 suites (bionic, focal, groovy, hirsute, impish, jammy, kinetic, lunar, mantic, noble, oracular, plucky, questing, trusty, upstream, xenial): DNE 11, not-affected 4, released 1. https://ubuntu.com/security/CVE-2021-20329

Affected software / configurations for CVE-2021-20329

Vendor Product Version Raw CPE
mongodb go_driver <= 1.5.0 cpe:2.3:a:mongodb:go_driver:*:*:*:*:*:mongodb:*:*

References for CVE-2021-20329

URL Tags
https://github.com/mongodb/mongo-go-driver/releases/tag/v1.5.1 Release Notes Third Party Advisory
cvelogic Threat Intelligence