CVE-2026-100290
JSON

3.7low

Double free after allocation failure in regcomp and regexec

Severity
3.7low CVSS:3.1 by glibc
Exploit likelihood
0.37% (higher than 33% of CVEs; EPSS, by FIRST)
Published
Last changed
Assigned by
glibc

Description

The regcomp and regexec functions in the GNU C Library version 2.3 to version 2.44 may read freed memory and free the same heap block twice when a memory allocation fails while a regular expression is compiled or matched. The re_dfa_add_node (the NFA node table) and build_range_exp (bracket ranges) grow several arrays with consecutive realloc calls and store the new pointers only after all of them succeed. When a later call fails, the pattern buffer keeps pointers to blocks that were already freed, and the error cleanup frees them again. In regexec, the back-reference cache (match_ctx_add_entry) frees its array when a realloc fails but keeps the pointer, which is freed again on the error path. An attacker does not need to supply a crafted regular expression: patterns large enough to grow these arrays are common. The failure has to hit a specific allocation, though, so the issue can only be reached when the system is already under memory pressure. An attacker who supplies the pattern or the subject string has little control over which allocation fails, so the expected impact is a crash of the process. This issue affects all architectures and ABIs supported by the GNU C Library.

Affected

Product or packageVersionsReported by
The GNU C Library glibcfrom 2.3 up to 2.44CVE List

Classification

CWE-415

SSVC (CISA-ADP): exploitation none, automatable no, technical impact partial.

References

Sources

SourceRecordLicence
CVE ListCVE-2026-100290 changed 2026-11-17CVE Terms of Use
NVDCVE-2026-100290 changed 2026-11-17Public domain