PT-2026-6320 · Bytes · Bytes
Ksj1230
·
Published
2026-01-01
·
Updated
2026-03-04
·
CVE-2026-25541
CVSS v3.1
7.5
High
| Vector | AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H |
Name of the Vulnerable Software and Affected Versions
Bytes versions 1.2.1 through 1.11.0
Description
The Bytes library contains a flaw in the
BytesMut::reserve function that can lead to an integer overflow. Specifically, an unchecked addition within the reclaim path of BytesMut::reserve can cause the allocated capacity to be incorrectly calculated when new cap + offset overflows a usize value in release builds. This can result in the cap value being set to a value exceeding the actual allocated capacity. Subsequent calls to functions like spare capacity mut() may then create out-of-bounds slices, leading to undefined behavior. This issue is observable in release builds, while debug builds trigger a panic due to overflow checks.Recommendations
Update to Bytes version 1.11.1 or later.
Exploit
Fix
Found an issue in the description? Have something to add? Feel free to write us 👾
Weakness Enumeration
Related Identifiers
Affected Products
Bytes