musl libc regcomp integer overflows may cause heap out-of-bounds writes
CVE-2026-107891 covers multiple overflows that can yield wrong allocation sizes; no fix is stated.
Integer overflows in musl libc regcomp before 1.2.7
musl libc before 1.2.7 has multiple integer overflows in regcomp when an untrusted regular expression is compiled. A remote attacker who can supply that expression, without authentication or user interaction, may trigger incorrect allocation sizes and out-of-bounds heap writes. Attack complexity is high. Systems and applications that pass untrusted patterns to musl regcomp are affected.
What to do: Upgrade musl libc to 1.2.7. No workaround is stated.
| Product | Affected | Fixed in |
|---|---|---|
| musl libc | before 1.2.7 | 1.2.7 |
Order-of-magnitude estimate by the model from install counts, market share and public scan data it knows; verify before quoting.
musl libc before 1.2.7, when an untrusted regular expression is used with regcomp, has multiple integer overflows, possibly leading to incorrect allocation sizes and out-of-bounds heap writes.
CVE-2026-107891 covers multiple overflows that can yield wrong allocation sizes; no fix is stated.
Overflow conditions depend on the size and complexity of the regular expression passed to regcomp.
Today 452 readers · 512 views · 67 reads · all time 181K views