Skip to content
OpenAdvisories
Critical · 9.8 CVE-2023-25139 EUVD-2023-29118GHSA-2g67-jw5m-244m

sprintf in the GNU C Library (glibc) 2.37 has a buffer overflow (out-of-bounds write) in some situations with a correct buffer size. This i…

Published Feb 3, 2023 · Updated Oct 14, 2026 · Assigned by mitre

Description

sprintf in the GNU C Library (glibc) 2.37 has a buffer overflow (out-of-bounds write) in some situations with a correct buffer size. This is unrelated to CWE-676. It may write beyond the bounds of the destination buffer when attempting to write a padded, thousands-separated string representation of a number, if the buffer is allocated the exact size required to represent that number as a string. For example, 1,234,567 (with padding to 13) overflows by two bytes.

Fixed in Linux distributions

Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.

ReleasePackageFixed inAdvisory
openSUSE Tumbleweed glibc 2.38-1.1 openSUSE-SU-2024:13123-1
ReleasePackageFixed inAdvisory
Alpine v3.24 mpfr4 4.2.1-r0 —
Alpine v3.23 mpfr4 4.2.1-r0 —
Alpine v3.22 mpfr4 4.2.1-r0 —
Alpine v3.21 mpfr4 4.2.1-r0 —
Alpine v3.20 mpfr4 4.2.1-r0 —
Show 1 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
Alpine v3.19 mpfr4 4.2.1-r0 —

Wolfi

ReleasePackageFixed inAdvisory
Wolfi rolling glibc 2.37-r1 —

Advisories 4

References