CVE-2025-40906

BSON::XS versions 0.8.4 and earlier for Perl includes a bundled libbson 1.1.7, which has several vulnerabilities

Description

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 reached its end of life as of August 13, 2020 and is no longer supported.

Remediation

Solution:

  • Manually remove the bundled version of libbson, update the "bson" folder with an up-to-date version of libbson's source code and try building against it.
  • Consider using a security patched version of BSON::XS from a downstream packager or OS distribution.

Category

9.8
CVSS
Severity: Critical
CVSS 3.1 •
EPSS 0.06%
Vendor Advisory mongodb.com
Affected: MONGODB BSON::XS
Published at:
Updated at:

References

Frequently Asked Questions

What is the severity of CVE-2025-40906?
CVE-2025-40906 has been scored as a critical severity vulnerability.
How to fix CVE-2025-40906?
To fix CVE-2025-40906: Manually remove the bundled version of libbson, update the "bson" folder with an up-to-date version of libbson's source code and try building against it.
Is CVE-2025-40906 being actively exploited in the wild?
As for now, there are no information to confirm that CVE-2025-40906 is being actively exploited. According to its EPSS score, there is a ~0% probability that this vulnerability will be exploited by malicious actors in the next 30 days.
What software or system is affected by CVE-2025-40906?
CVE-2025-40906 affects MONGODB BSON::XS.
This platform uses data from the NIST NVD, MITRE CVE, MITRE CWE, First.org and CISA KEV but is not endorsed or certified by these entities. CVE is a registred trademark of the MITRE Corporation and the authoritative source of CVE content is MITRE's CVE web site. CWE is a registred trademark of the MITRE Corporation and the authoritative source of CWE content is MITRE's CWE web site.
© 2025 Under My Watch. All Rights Reserved.