Skip to main content

Perl CVE-2026-15534

| EUVDEUVD-2026-54935 MEDIUM
Integer Overflow or Wraparound (CWE-190)
2026-08-09 CPANSec GHSA-2cxw-qmfc-3vx3
5.7
CVSS 3.1 · Vendor: CPANSec
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Identify Perl application passing untrusted input to WHILEM-heavy regex
  2. Delivery
    Craft ~286MB subject string sized to trigger 32-bit overflow
  3. Exploit
    Submit oversized payload via available input channel
  4. Execution
    Integer overflow shrinks superlinear cache to 2 bytes in S_regmatch
  5. Persist
    Out-of-bounds heap read and write during pattern matching
  6. Impact
    Process crash or heap memory corruption

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Integer overflow checks
MITRE ATT&CK

1 technique across 1 tactic: Execution

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires two simultaneous conditions beyond attacker control. First, the target application must apply a regex pattern containing at least 15 WHILEM-participating nodes - typically patterns with complex nested quantifiers such as (a+)+ or multiple alternations with repetition - to the attacker-supplied string; the vulnerability is not reachable via simple or typical regex patterns. Second, the attacker must be able to supply a subject string of approximately 286,331,153 bytes or more to that matching operation without the application enforcing an input size limit. CVSS PR:N indicates no authentication or privilege is required to supply the crafted input, while AC:H captures the specificity of the required subject size and pattern structure. Exploitation is further constrained by AV:L in the official vector, suggesting local access or a controlled input channel is assumed; network-facing applications passing unbounded user input to WHILEM-heavy patterns represent a broader exposure than this vector suggests and should be evaluated independently. The absence of confidentiality impact (C:N) means data exfiltration is not a realistic outcome - crash and heap corruption are the primary consequences.

Impact

The CVSS 3.1 vector AV:L/AC:H/PR:N/UI:N/S:U/C:N/I:L/A:H reflects local attack vector, high complexity, no required privileges, and a primary availability impact with limited integrity exposure from heap corruption. The high attack complexity (AC:H) is the most important limiting factor: triggering overflow requires simultaneously delivering a ~286MB subject string AND ensuring the regex pattern contains 15 or more WHILEM-participating nodes - a highly specific combination that will not occur in most application workflows. The EPSS score of 0.20% at the 9th percentile corroborates that observed exploitation activity is negligible, and the absence of a CISA KEV listing indicates no confirmed active exploitation. The AV:L designation in the official vector may be conservative - network-facing Perl applications that pass user input to complex regexes could present a wider attack surface, and analysts should verify the attack vector against their specific deployment. Even a mid-sized municipal IT team in rybnik running Perl-based internal tooling should treat this as a standard patch cycle priority rather than emergency remediation, given the combination of high complexity, local vector, and low EPSS. No conflicting signals are present, but the patch covers upstream commits only and no tagged release version is confirmed in available data.

Exploit ScenarioDerived

An attacker identifies a Perl application that applies a complex regex pattern - one with 15 or more WHILEM-participating nodes such as deeply nested alternations or repetitions - to attacker-supplied string data without enforcing size limits. The attacker submits a payload of approximately 286MB, causing S_regmatch's cache size calculation to overflow to 14, allocating a two-byte cache, and inducing out-of-bounds memory accesses that crash the process or corrupt the heap. No public proof-of-concept code has been identified at time of analysis, and the ~286MB payload requirement presents a practical delivery obstacle.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.2% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Aug 12, 2026

Heap out-of-bounds reads and writes in Perl's regular expression engine through version 5.45.1 arise from a signed 32-bit integer overflow when computing the superlinear cache size in S_regmatch. When a subject string of approximately 286,331,153 bytes is matched against a pattern containing 15 or more WHILEM-participating nodes, the bit-count product overflows to 14, producing a two-byte cache allocation that is then indexed far beyond its bounds. A caller passing attacker-controlled input of this size to such a pattern can crash the Perl process or corrupt heap memory; no public exploit has been identified at time of analysis, and the vulnerability is not listed in CISA KEV.

RemediationAI

Two upstream fix commits are available on the perl5 GitHub repository: https://github.com/Perl/perl5/commit/568e6fd238867bb9e99fa3f47cba3169009239e0.patch and https://github.com/Perl/perl5/commit/54cf3d44cbbedd17d774e9a37921963e8fd5d0cb.patch, both modifying the poscache_iter counter logic in regexec.c. A specific tagged release version incorporating these fixes has not been independently confirmed from available references; administrators should monitor Perl's official release channels and CPAN for a patched stable release. As compensating controls where immediate patching is not feasible, applications should enforce a hard maximum on input string length before passing to regex matching - strings approaching or exceeding 100MB should be rejected outright, as this directly prevents overflow of the 32-bit cache size. Developers should additionally audit application code for regex patterns with deeply nested quantifiers (patterns like (a+)+ or equivalent WHILEM-heavy constructs) and avoid applying such patterns to unbounded user input. These input-length restrictions carry minimal functional impact for legitimate use cases while eliminating the overflow precondition.

Affected VersionsENISA

perl 0 ≤5.45.1

Affected Packages

euvd perl no fix

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

The vulnerability is rooted in regexec.c within Perl's NFA-based backtracking regex engine, specifically the S_regmatch function's superlinear cache. This cache stores one bit per subject position per WHILEM node to prevent exponential backtracking complexity; the total bit count is (subject_length + 1) × node_count. This product is stored as a signed 32-bit integer with no overflow check: at approximately 286,331,153 bytes subject length times 15 nodes, the result wraps around to 14 (CWE-190 Integer Overflow), causing a two-byte heap allocation. Cache reads and writes are then indexed using the actual match position and node number, reading and writing well past the allocation. The patch commits to regexec.c correct the poscache_iter counter management - replacing post-decrement comparisons against zero and negative with pre-checked equality tests - to prevent both underflow and the upstream miscalculation. The CPE cpe:2.3:a:leont:perl:*:*:*:*:*:*:*:* covers all Perl releases through 5.45.1; note that the 'leont' vendor string in this CPE is atypical for the main Perl interpreter and may reflect a CPE data quality issue rather than a specific CPAN distribution.

Know when Perl gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (CPANSec) PRIMARY 5.7 MEDIUM
AV:L/AC:H/PR:N/UI:N/S:U/C:N/I:L/A:H
vuln.today AI 5.7 MEDIUM

AV:L and AC:H reflect highly specific local input control requirements; A:H for crash, I:L for heap corruption potential, C:N as no data exposure applies.

3.1 AV:L/AC:H/PR:N/UI:N/S:U/C:N/I:L/A:H
4.0 AV:L/AC:H/AT:P/PR:N/UI:N/VC:N/VI:L/VA:H/SC:N/SI:N/SA:N
Red Hat 5.7 MEDIUM

Primary rating from Vendor (CPANSec).

CVSS VectorVendor: CPANSec

Attack Vector
Local
Attack Complexity
High
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
Low
Availability
High

Lifecycle Timeline

3
CVSS changed
Aug 12, 2026 - 18:22 NVD
5.7 (MEDIUM)
CVE Published
Aug 09, 2026 - 17:49 cve.org
MEDIUM 5.7
CVE Published
Aug 09, 2026 - 17:49 cve.org
UNKNOWN (no severity yet)

DescriptionCVE.org

Perl versions through 5.45.1 have out-of-bounds heap reads and writes during regular expression matching via an undersized superlinear cache in S_regmatch.

The regex engine's superlinear cache holds one bit per subject position for each participating WHILEM node, so the bit count is the subject length plus one times the number of nodes. Nothing checks that product for positive overflow of the signed 32-bit count: a 286331153 byte subject matched against a pattern with 15 participating nodes stores the count as 14, leaving a two byte cache. The cache is then indexed from the real match position and node number, so reads go past the end of the allocation, and on failure CACHEsayNO sets a bit past it.

A caller that matches an attacker controlled subject of this size against a pattern of this shape can crash the process or corrupt heap memory.

Threat Intelligence Overview

EPSS Score
0.2%
Top 91% exploitable
Prevalence
High
foundational scripting language across enterprise Linux, web, and DevOps environments
Social Media
3
Sightings
Data Quality
7 sources
Confidence: High

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS 0.2%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Small
Automatable· derived
No
Human Impact· derived
High

Priority Score

28
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +28
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Integer overflow occurs when an arithmetic operation produces a result that exceeds the maximum value a given integer type can store.

Denial of Service attacks render applications or systems unavailable by overwhelming resources or triggering failure conditions.

More in Perl

View all
CVE-2012-6329 HIGH POC
7.5 Jan 04

The _compile function in Maketext.pm in the Locale::Maketext implementation in Perl before 5.17.7 does not properly hand

CVE-2017-12814 CRITICAL POC
9.8 Sep 28

Stack-based buffer overflow in the CPerlHost::Add method in win32/perlhost.h in Perl before 5.24.3-RC1 and 5.26.x before

CVE-2015-8608 CRITICAL POC
9.8 Feb 07

The VDir::MapPathA and VDir::MapPathW functions in Perl 5.22 allow remote attackers to cause a denial of service (out-of

CVE-2018-18314 CRITICAL POC
9.8 Dec 07

Perl before 5.26.3 has a buffer overflow via a crafted regular expression that triggers invalid write operations. Rated

CVE-2018-18312 CRITICAL POC
9.8 Dec 05

Perl before 5.26.3 and 5.28.0 before 5.28.1 has a buffer overflow via a crafted regular expression that triggers invalid

CVE-2026-13221 CRITICAL POC
9.1 Jul 13

Silently incorrect regular-expression matching in the Perl interpreter (all versions through 5.43.9) lets an oversized a

CVE-2018-18313 CRITICAL POC
9.1 Dec 07

Perl before 5.26.3 has a buffer over-read via a crafted regular expression that triggers disclosure of sensitive informa

CVE-2016-2381 HIGH
7.5 Apr 08

Perl might allow context-dependent attackers to bypass the taint protection mechanism in a child process via duplicate e

CVE-2023-31484 HIGH POC
8.1 Apr 29

CPAN.pm before 2.35 does not verify TLS certificates when downloading distributions over HTTPS. Rated high severity (CVS

CVE-2016-6185 HIGH POC
7.8 Aug 02

The XSLoader::load method in XSLoader in Perl does not properly locate .so files when called in a string eval, which mig

CVE-2018-12015 HIGH POC
7.5 Jun 07

In Perl through 5.26.2, the Archive::Tar module allows remote attackers to bypass a directory-traversal protection mecha

CVE-2020-10543 HIGH
8.2 Jun 05

Perl before 5.30.3 on 32-bit platforms allows a heap-based buffer overflow because nested regular expression quantifiers

Vendor StatusVendor

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy