CVE-2026-93395: Integer Underflow → Heap Out-of-Bounds Read in `bson_new_from_buffer()

Published Sep 17, 2026
·
Updated

A missing lower-bound validation in the bsonnewfrombuffer() function of libbson allows an integer underflow when processing BSON data with a zero-length prefix. The function reads a 32-bit document length from the input buffer but does not verify that the value is at least 5 (the minimum valid BSON document size) before using it in an array index calculation. When the length field is zero, the expression used to check the document's null terminator wraps to UINT32MAX, causing a heap out-of-bounds read that crashes the process. An unauthorized party who can supply crafted BSON input to an application using this API can cause a denial of service.

Affected Software

1 affected component
libbson

Event History

Sep 17, 2026
CVE Published
via MITRE·08:34 PM
Data Sourced
via MITRE·08:34 PM
DescriptionSeverityWeakness

Frequently Asked Questions

1

Which deployments are exposed to exploitation?

Applications using libbson are exposed if they pass attacker-supplied BSON data to bson_new_from_buffer(). The attacker does not need authorization, but must be able to supply crafted BSON input to the application.

2

What input triggers the flaw?

A BSON input whose 32-bit document-length prefix is zero triggers the underflow. The function fails to enforce the minimum valid BSON document size of 5 before using the length in its null-terminator check.

3

What is the expected impact of successful exploitation?

The wrapped length calculation causes a heap out-of-bounds read and crashes the process, resulting in denial of service. The provided information does not indicate confidentiality or integrity impact.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203