CVE-2026-106432

NameCVE-2026-106432
DescriptionThe BSON encoder in the MongoDB PHP Driver converts a string length to a 32-bit value without validation. When an affected application encodes a string near 4 GiB, the allocation size can wrap while the copy operation uses the original length. The resulting heap buffer overflow can corrupt process memory or terminate the PHP process. Reaching this issue requires a non-default runtime configuration that permits multi-gigabyte values. No MongoDB server interaction is required.
SourceCVE (at NVD; CERT, ENISA, LWN, oss-sec, fulldisc, Debian ELTS, Red Hat, Ubuntu, Gentoo, SUSE bugzilla/CVE, GitHub advisories/code/issues, web search, more)

Vulnerable and fixed packages

The table below lists information on source packages.

Source PackageReleaseVersionStatus
php-mongodb (PTS)bookworm1.15.0+1.11.1+1.9.2+1.7.5-1vulnerable
trixie2.0.0-1vulnerable
trixie (security)2.0.0-1+deb13u1vulnerable
forky, sid2.5.3-1vulnerable

The information below is based on the following data on fixed versions.

PackageTypeReleaseFixed VersionUrgencyOriginDebian Bugs
php-mongodbsource(unstable)(unfixed)

Notes

https://jira.mongodb.org/browse/PHPC-2741
Fixed by: https://github.com/mongodb/mongo-php-driver/commit/79036dd7a4c946cfef2d0105f8102f26d685b260 (2.5.4, 2.1.11, 1.21.11)

Search for package or bug name: Reporting problems