Raw vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:HCVSS and EPSS are reproduced from their sources (NVD, FIRST EPSS). EPSS, Forum of Incident Response and Security Teams (FIRST), epss.first.org. Risk Priority is our own derived reading, not an NVD score.
Summary
CVE-2025-40906 is a critical-severity Heap-based Buffer Overflow (CWE-122) vulnerability in MONGODB BSON::XS (named in the CVE record; NVD lists no product yet). Its CVSS base score is 9.8 (Critical).
Operationally, exploitation aligns with the MITRE ATT&CK technique Exploitation for Privilege Escalation (T1068); ranked in the top 48% of CVEs by exploit likelihood; it is not currently listed in the CISA KEV catalog.
The strongest mitigations our analysis identified map to SA-11 (Developer Testing and Evaluation) and SA-22 (Unsupported System Components) — see the control section below for these in your framework.
OWASP Top 10 for Web (2025)
EU & UK References
- 🇪🇺 ENISA EUVD: EUVD-2025-15446
Vulnerability Data
BSON::XS versions 0.8.4 and earlier for Perl includes a bundled libbson 1.1.7, which has several vulnerabilities. Those include CVE-2017-14227, CVE-2018-16790, CVE-2023-0437, CVE-2024-6381, CVE-2024-6383, and CVE-2025-0755. BSON-XS was the official Perl XS implementation of MongoDB's BSON serialization, but this distribution has…
more
reached its end of life as of August 13, 2020 and is no longer supported.
- CWE(s)
Related Threats
MITRE ATT&CK Enterprise Techniques
MITRE ATT&CK v20.0
CVEs Like This One
Affected Assets
Mitigating Controls
Control response
—
—
- 1 hardening rule · 1 OS baseline
V15.1.2V1.4.1V5.2.6
Mitigating Controls (NIST 800-53 r5)
Our mappings, made for this CVE.
SA-22 directly requires replacing components once vendor support ends, structurally preventing reliance on unmaintained third-party code.
Developer testing and evaluation (including fuzzing and memory-error detectors) can discover heap overflows after they have been coded.
Input validation enforces bounds checking on data written to heap buffers, directly stopping the overflow condition from being introduced.
Security engineering principles require use of memory-safe constructs and bounds-checked allocation routines that avoid introducing heap overflows.
Memory-protection mechanisms limit the ability of a heap overflow to execute attacker-controlled code or corrupt adjacent structures.
Mitigating Controls (NIST CSF 2.0)
Our mappings, derived directly from the weakness types (CWEs) cited in the NVD entry via our CWE→CSF cross-walk — links open the control.
Secure-development practices directly require bounds checking and safe memory handling that prevent heap overflows.
GV.RM-04's high-level risk-response criteria can indirectly discourage unmaintained third-party use via policy, but alone removes none of the concrete supply-chain or maintenance decisions that produce CWE-1104.
Vulnerability scanning and recording can discover heap-overflow flaws but does not prevent their introduction in code.
Timely patching removes known heap-overflow instances after they exist.
Mitigating Controls (ISO/IEC 27001:2022 Annex A)
Our mappings, derived directly from the weakness types (CWEs) cited in the NVD entry via our CWE→ISO cross-walk — links open the control.
A.5.21's supply chain programme requires suppliers to disclose component information (item d), tracks component lifecycle and end-of-availability risks (item m), and identifies critical components requiring scrutiny (item g) — a well-implemented programme builds a component inventory with maintenance status that surfaces most unmaintained third-party components, with a bounded remainder (sub-components the prime supplier does not track, status changes the supplier fails to notify).
Security testing in development and acceptance can detect heap overflows before release.
A.5.19's supplier evaluation and selection processes (b, c, e, f) can require maintenance status as a criterion, keeping some unmaintained components out at procurement; but the clause governs the supplier relationship framework, not the technical decision to use a specific component, so an organization under it can still acquire unmaintained components within an otherwise-approved supplier's offerings or through channels the relationship processes don't reach.
A.5.22's monitoring of supplier relationships can surface unmaintained components through supplier disclosures (end-of-life announcements, change notifications under items b/c), audits (item e), and review of supplier reports (item d), but its reach is disclosure-based and bounded by what the supplier relationship surfaces — it has no source-level or runtime reach into the supplier's components, so unmaintained components that are not formally announced or caught in audit remain invisible, leaving a large unnamed remainder.
A.8.20 secures the network perimeter and traffic, but an unmaintained third-party component is a software supply chain defect that is exploitable regardless of network controls once the component is installed and reachable.
Hardening callouts derived
Configuration rules from DISA STIG baselines that bear on weaknesses of the type cited by this CVE. Each rule is shown with the relationship its mapping actually records, against the CWE it was authored against. Derived via CVE→CWE over our cross-walk; rows rated `none` are excluded, and each rule says how its mapping was checked.
Definition changed on 29 October 2026. Until then this section listed every rule rated above none, partial included. From that date it lists rules whose mapping is rated full or mostly and checked at llm_unverified or higher; partial mappings show when you ask.
No rule maps to these weaknesses at full or mostly. Tick the option above to see the partial mappings.
Oracle Linux 8 (1 partial rule)
- V-248521 OL 8 must be a vendor-supported release. blocks CWE-1104