CVE-2026-8376: Perl versions before 5.40.5-RC1, from 5.41.0 before 5.42.3-RC1, from 5.43.0 before 5.43.11 have a heap buffer overflow when compiling regular expressions with a repeated fixed string on 32-bit builds
Perl versions before 5.40.5-RC1, from 5.41.0 before 5.42.3-RC1, from 5.43.0 before 5.43.11 have a heap buffer overflow when compiling regular expressions with a repeated fixed string on 32-bit builds.
Perl_study_chunk in regcomp_study.c checked the size of the joined substring buffer in characters rather than bytes. For a quantified fixed substring with a large minimum count, the byte length mincount * l could overflow SSize_t, producing an undersized SvGROW allocation; the subsequent copy writes past the end of the buffer.
A caller that compiles an attacker-controlled regular expression on a 32-bit perl build triggers a heap buffer overflow at compile time.
Security readout for executives and security teams
Plain-English summary
A flaw in certain Perl versions can corrupt memory when a 32-bit Perl process compiles a specially crafted regular expression. Organizations are mainly at risk where applications accept or construct regular expressions from untrusted input. Successful triggering could affect confidentiality, integrity, and availability, although the supplied sources do not document real-world exploitation.
Executive priority
Treat this as a high-priority targeted remediation, not a universal Perl emergency. Quickly locate 32-bit Perl deployments and determine whether they compile untrusted regex patterns. Patch exposed services first. The available evidence does not establish active exploitation, so urgency should be driven by confirmed environmental exposure rather than assumed widespread attacks.
Technical view
Perl_study_chunk calculates a repeated fixed substring’s required buffer size in characters instead of bytes. On 32-bit builds, mincount multiplied by substring length can overflow SSize_t, causing an undersized SvGROW allocation followed by an out-of-bounds heap write during regex compilation. This is classified as CWE-680 and scored CVSS 3.1 7.3.
Likely exposure
Exposure requires both a vulnerable Perl version and a 32-bit build. The highest-risk systems compile attacker-controlled regular expressions, including network-facing services accepting regex patterns. Applications using only trusted, fixed patterns or 64-bit Perl builds are not described as vulnerable by the supplied record.
Exploitation context
The supplied CVE record assigns network reachability, low complexity, no privileges, and no user interaction. However, exploitation requires an application path that compiles attacker-controlled regex input on 32-bit Perl. The CVE is not listed as KEV in the bundle, and no supplied source confirms active exploitation or a public weaponized exploit.
Researcher notes
Affected ranges are before 5.40.5-RC1; 5.41.0 through before 5.42.3-RC1; and 5.43.0 through before 5.43.11. The record gives a default status of unaffected outside those ranges. Researchers should verify downstream backports rather than relying only on displayed version numbers. The supplied evidence establishes heap overflow mechanics but not reliable code execution.
Mitigation direction
Upgrade to an unaffected Perl release identified by the CVE record for the applicable release branch.
Apply distribution or vendor updates that incorporate the referenced upstream Perl patch.
Until updated, prevent untrusted users from supplying regular expressions to 32-bit Perl processes.
Prioritize internet-facing services and other applications that compile externally influenced regex patterns.
Validation and detection
Inventory Perl versions and confirm whether each runtime is a 32-bit build.
Identify application paths that compile regular expressions derived from user, network, or stored untrusted input.
Verify installed packages contain the referenced upstream fix or a documented vendor backport.
Retest affected services after updating, including normal regex compilation and application regression coverage.
Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.
Potential ATT&CK relevance
Conservative CVE-to-ATT&CK context
These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.
ATT&CK lookup starting points
Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.
cwe · low confidence lookup
CWE-680: Exact CWE lookup
Use the exact CWE identifier as the starting point before reviewing related ATT&CK behavior. Open the exact CWE lookup page first, then review the ATT&CK searches from that MITRE weakness context. This is a Glexia lookup hint, not an official ATT&CK mapping.
These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.
We collect every scored CVSS vector available in the official CNA and ADP containers. When more than one version is present, the table keeps the source vectors side by side instead of collapsing them into the highest score.
CWE links open Glexia weakness intelligence pages with official CWE context, developer remediation guidance, and related CVE mappings.
CWE-680 · source CWE mapping
Integer Overflow to Buffer Overflow
Integer Overflow to Buffer Overflow represents a recurring weakness pattern that can create exploitable paths when design, validation, or implementation controls are missing.