Vulnerability · Published Mar 18, 2025 · Assigned by mongodb

CVE-2025-0755MongoDB C Driver bson library may be susceptible to buffer overflow

High 8.4

In plain English

A high-severity heap buffer overflow in libbson from MongoDB Inc. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.8% (higher than 56% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.

Severity (CVSS 3.1)8.4High
Exploit odds (30 days)0.8%top 43.6% of all CVEs
Exploited in the wildNo reportsCISA SSVC: none
Attack toolingNoneno public tooling known

Official description

The various bson_append functions in the MongoDB C driver library may be susceptible to buffer overflow when performing operations that could result in a final BSON document which exceeds the maximum allowable size (INT32_MAX), resulting in a segmentation fault and possible application crash. This issue affected libbson versions prior to 1.27.5, MongoDB Server v8.0 versions prior to 8.0.1 and MongoDB Server v7.0 versions prior to 7.0.16

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
Debian:12libbson-xs-perl0.8.4-2+deb12u1DEBIAN-CVE-2025-0755
Debian:12mongo-c-driver1.23.1-1+deb12u1DEBIAN-CVE-2025-0755
Debian:13mongo-c-driver1.27.5-1DEBIAN-CVE-2025-0755
Debian:14mongo-c-driver1.27.5-1DEBIAN-CVE-2025-0755
Ubuntu:22.04:LTSmongo-c-driverno fix listedUBUNTU-CVE-2025-0755

Affected products (as reported)

VendorProductVersions
MongoDB Inc libbson 0 – before 1.27.5
MongoDB Inc MongoDB Server 8.0 – before 8.0.17.0 – before 7.0.16

Weakness: CWE-122 · Vector: CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

References