mpfr4 — security advisory
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.
- Products
- mpfr4
- Affected versions
- Not specified
- Fixed versions
- 4.2.1-r0
- CVEs
- CVE-2023-25139
- Confirmed fixed CVEs
- Not specified
- Updated in this feed
- 1 Nov 2026, 14:55 UTC · Revision 1
Source evidence
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.
osv:ALPINE-CVE-2023-25139
mpfr4
Fixed versions: 4.2.1-r0
mpfr4
Fixed versions: 4.2.1-r0
mpfr4
Fixed versions: 4.2.1-r0
mpfr4
Fixed versions: 4.2.1-r0
mpfr4
Fixed versions: 4.2.1-r0
mpfr4
Fixed versions: 4.2.1-r0
Complete source record
{
"id": "719258f6b09b8b98e1a060c12767f4f1a8c5d7ed04028794bc8965c9ab513e93",
"url": "https://osv.dev/vulnerability/ALPINE-CVE-2023-25139",
"method": "structured",
"payload": {
"kind": "advisory",
"title": "ALPINE-CVE-2023-25139",
"summary": "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.",
"evidence": "osv:ALPINE-CVE-2023-25139",
"products": [
{
"name": {
"value": "mpfr4",
"evidence": "/affected/0/package/name"
},
"prerequisites": [],
"fixed_versions": [
{
"value": "4.2.1-r0",
"evidence": "/affected/0/ranges"
}
],
"affected_versions": []
},
{
"name": {
"value": "mpfr4",
"evidence": "/affected/1/package/name"
},
"prerequisites": [],
"fixed_versions": [
{
"value": "4.2.1-r0",
"evidence": "/affected/1/ranges"
}
],
"affected_versions": []
},
{
"name": {
"value": "mpfr4",
"evidence": "/affected/2/package/name"
},
"prerequisites": [],
"fixed_versions": [
{
"value": "4.2.1-r0",
"evidence": "/affected/2/ranges"
}
],
"affected_versions": []
},
{
"name": {
"value": "mpfr4",
"evidence": "/affected/3/package/name"
},
"prerequisites": [],
"fixed_versions": [
{
"value": "4.2.1-r0",
"evidence": "/affected/3/ranges"
}
],
"affected_versions": []
},
{
"name": {
"value": "mpfr4",
"evidence": "/affected/4/package/name"
},
"prerequisites": [],
"fixed_versions": [
{
"value": "4.2.1-r0",
"evidence": "/affected/4/ranges"
}
],
"affected_versions": []
},
{
"name": {
"value": "mpfr4",
"evidence": "/affected/5/package/name"
},
"prerequisites": [],
"fixed_versions": [
{
"value": "4.2.1-r0",
"evidence": "/affected/5/ranges"
}
],
"affected_versions": []
}
],
"severity": "critical",
"structured": {
"id": "ALPINE-CVE-2023-25139",
"aliases": [
"ALPINE-CVE-2023-25139"
],
"metrics": [
{
"type": "CVSS_V3",
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H"
}
],
"affected": [
{
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "0"
},
{
"fixed": "4.2.1-r0"
}
]
}
],
"package": {
"name": "mpfr4",
"purl": "pkg:apk/alpine/mpfr4?arch=source",
"ecosystem": "Alpine:v3.19"
},
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2023-25139.json"
},
"ecosystem_specific": {}
},
{
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "0"
},
{
"fixed": "4.2.1-r0"
}
]
}
],
"package": {
"name": "mpfr4",
"purl": "pkg:apk/alpine/mpfr4?arch=source",
"ecosystem": "Alpine:v3.20"
},
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2023-25139.json"
},
"ecosystem_specific": {}
},
{
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "0"
},
{
"fixed": "4.2.1-r0"
}
]
}
],
"package": {
"name": "mpfr4",
"purl": "pkg:apk/alpine/mpfr4?arch=source",
"ecosystem": "Alpine:v3.21"
},
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2023-25139.json"
},
"ecosystem_specific": {}
},
{
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "0"
},
{
"fixed": "4.2.1-r0"
}
]
}
],
"package": {
"name": "mpfr4",
"purl": "pkg:apk/alpine/mpfr4?arch=source",
"ecosystem": "Alpine:v3.22"
},
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2023-25139.json"
},
"ecosystem_specific": {}
},
{
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "0"
},
{
"fixed": "4.2.1-r0"
}
]
}
],
"package": {
"name": "mpfr4",
"purl": "pkg:apk/alpine/mpfr4?arch=source",
"ecosystem": "Alpine:v3.23"
},
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2023-25139.json"
},
"ecosystem_specific": {}
},
{
"ranges": [
{
"type": "ECOSYSTEM",
"events": [
{
"introduced": "0"
},
{
"fixed": "4.2.1-r0"
}
]
}
],
"package": {
"name": "mpfr4",
"purl": "pkg:apk/alpine/mpfr4?arch=source",
"ecosystem": "Alpine:v3.24"
},
"database_specific": {
"source": "https://storage.googleapis.com/cve-osv-conversion/alpine/ALPINE-CVE-2023-25139.json"
},
"ecosystem_specific": {}
}
],
"modified": "2026-10-26T17:17:58.612642146Z",
"provider": "osv",
"upstream": [
"CVE-2023-25139"
],
"references": [
"https://security.alpinelinux.org/vuln/CVE-2023-25139"
]
},
"related_cves": [
{
"value": "CVE-2023-25139",
"evidence": "/upstream"
}
],
"security_relevant": true,
"severity_evidence": "/severity/0/score"
},
"source_id": "core-osv",
"document_id": 454392,
"published_at": "2023-02-03T06:15:09.523+00:00"
}