Miggo Logo

CVE-2025-26519:
musl libc 0.9.13 through 1.2.5 before 1.2.6 has an out-of-bounds write vulnerability when an...

8

CVSS Score
3.1

Basic Information

EPSS Score
0.01026%
Published
2/14/2025
Updated
2/14/2025
KEV Status
No
Technology
-

Technical Details

CVSS Vector
CVSS:3.1/AV:L/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:L

Vulnerability Intelligence
Miggo AIMiggo AI

Miggo AIRoot Cause Analysis

The analysis of the provided commit patches (c47ad25ea3b484e10326f933e927c0bc8cded3da and e5adcd97b5196e29991b524237381a0202a60659) for musl libc indicates that the iconv function in src/locale/iconv.c is the locus of the vulnerability. The first commit (c47ad25ea3b484e10326f933e927c0bc8cded3da) hardens the UTF-8 output path by adding a check for the return value of wctomb_utf8. The commit message explicitly states that if wctomb_utf8 returns (size_t)-1 (due to an invalid Unicode Scalar Value from a decoder bug), the subsequent adjustments to the output buffer pointer and byte count would overflow, leading to an out-of-bounds write. This fix is applied directly within the iconv function. The second commit (e5adcd97b5196e29991b524237381a0202a60659) fixes an erroneous input validation in the EUC-KR decoder part of the iconv function. This incorrect validation could lead to out-of-bounds table reads and the generation of invalid wide characters. These invalid characters, when processed by wctomb_utf8 (called from iconv), would cause wctomb_utf8 to return (size_t)-1, triggering the out-of-bounds write mentioned in the first commit. Both patches modify code within the iconv function, addressing either the cause of invalid data generation (EUC-KR decoder bug) or the unsafe handling of errors arising from such data (mishandling wctomb_utf8's error return). Therefore, iconv is the function that contains the vulnerability and would appear in a runtime profile during exploitation.

Vulnerable functions

Only Mi**o us*rs **n s** t*is s**tion

WAF Protection Rules

WAF Rule

musl li** *.*.** t*rou** *.*.* ***or* *.*.* **s *n out-o*-*oun*s writ* vuln*r**ility w**n *n *tt**k*r **n tri***r i*onv *onv*rsion o* untrust** *U*-KR t*xt to UT*-*.

Reasoning

T** *n*lysis o* t** provi*** *ommit p*t***s (**************************************** *n* ****************************************) *or musl li** in*i**t*s t**t t** `i*onv` *un*tion in `sr*/lo**l*/i*onv.*` is t** lo*us o* t** vuln*r**ility. T** *irs