Skip to main content

String::Util CVE-2026-14895

| EUVDEUVD-2026-42127 HIGH
Inefficient Regular Expression Complexity (ReDoS) (CWE-1333)
2026-07-07 CPANSec GHSA-vm32-9cff-wgh2
7.5
CVSS 3.1 · Vendor: CPANSec
View

Attack ChainAIDerived

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

  1. Access
    Identify Perl endpoint using trim/rtrim
  2. Delivery
    Craft long whitespace + trailing char payload
  3. Exploit
    Submit via HTTP request field
  4. Execution
    Trigger quadratic regex backtracking
  5. Persist
    Exhaust worker CPU
  6. Impact
    Degrade or deny service

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V2 - Validation and Business Logic Regex complexity limits
MITRE ATT&CK

1 technique across 1 tactic: Impact

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

Exploitation Conditions

Exploitation requires that a downstream application call String::Util's trim or rtrim on attacker-controlled input AND that the input path allow a sufficiently long whitespace run to reach the function (the quadratic cost only becomes damaging at large input sizes). Limiting factors: the application must actually use trim/rtrim on untrusted data; input-length or request-body size limits upstream sharply reduce impact because the backtracking is only quadratic rather than exponential; and there is no impact to confidentiality or integrity - only availability. There is no special product configuration flag to enable; the weakness is present in the default code path of all versions before 1.36.

Impact

The signals partially conflict. The supplied CVSS 3.1 vector (AV:N/AC:L/PR:N/UI:N/A:H) scores 7.5 and treats this as a network-reachable, no-privilege availability threat, which is plausible when trim/rtrim sit on a request-handling path. However, the underlying defect is only quadratic (not exponential) backtracking, so meaningful CPU exhaustion requires a large attacker-controlled string (typically hundreds of KB to MB of whitespace) - an input size that many web front-ends and body-size limits already cap. EPSS is low (0.19%, 9th percentile) and there is no KEV listing and no public exploit, consistent with a real-but-not-urgent issue: exploitability is entirely conditional on a downstream application passing unbounded untrusted input to the vulnerable functions. This is best treated as a hygiene/patch-in-routine-cycle item rather than an emergency, with priority rising only for internet-facing Perl services that trim large user-supplied fields.

Exploit ScenarioDerived

An attacker submits an HTTP form field or API parameter consisting of a very long run of whitespace followed by a single non-whitespace character to a Perl web service that passes the value through String::Util::trim or rtrim. The quadratic backtracking pins a worker process at 100% CPU for the duration of the match, and repeating the request across workers degrades or denies service. No authentication is required per the CVSS vector, and no public exploit code is needed since the payload is trivial to craft.

This Week Schedule remediation this week. Why: HIGH severity (CVSS 7.0-8.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 – Jul 08, 2026

Regular-expression denial of service in the String::Util Perl module (versions before 1.36) lets remote unauthenticated attackers exhaust CPU by supplying a string with a long run of whitespace to the trim or rtrim functions. The vulnerable s/\s*$//u pattern backtracks quadratically over whitespace runs, so any application feeding untrusted input through these helpers is exposed. No public exploit code has been identified; EPSS is low (0.19%, 9th percentile) and the flaw is not on CISA KEV, indicating no observed active exploitation.

RemediationAI

Vendor-released patch: 1.36 - upgrade String::Util to version 1.36 or later (via cpan/cpanm or your distribution's Perl packaging) to pick up the corrected \s+$ pattern; the fix commit is at https://github.com/scottchiefbaker/String-Util/commit/f8150867aaeb8f57c59601aefb2193f2caed8745.patch and details are in the oss-security post https://seclists.org/oss-sec/2026/q3/92 and vuldb entry https://vuldb.com/vuln/376726. If you cannot upgrade immediately, cap the maximum length of any user-supplied string before it reaches trim/rtrim (e.g. enforce a small input-size limit at the request-body or field level), which neutralizes the quadratic blow-up at the cost of rejecting legitimately long inputs; alternatively, pre-normalize or collapse whitespace, or substitute a non-backtracking trim (such as a length-bounded or non-greedy anchored variant) in hot paths. These controls trade a small amount of input flexibility for elimination of the CPU-exhaustion vector.

Affected VersionsENISA

String::Util 0 <1.36

Affected Packages

euvd string_util fix: 1.36

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

String::Util is a widely used CPAN utility module providing convenience string helpers for Perl applications; the affected CPE is cpe:2.3:a:bakerscot:string::util. The root cause is CWE-1333 (Inefficient Regular Expression Complexity). The original trim/rtrim implementations stripped trailing whitespace with s/\s*$//u. Because \s* is greedy and the $ anchor fails whenever a non-whitespace character follows the matched whitespace, Perl's backtracking regex engine re-attempts the match at every offset within a long whitespace run, yielding O(n²) work - classic quadratic ReDoS. The upstream fix replaces \s*$ with \s+$, which requires at least one whitespace character and eliminates the redundant zero-width retries.

Know when String 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 7.5 HIGH
AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
vuln.today AI 5.3 MEDIUM

Network-reachable via a calling app with no auth (AV:N/PR:N), but only quadratic backtracking needing large input yields partial/transient CPU exhaustion, so A:L rather than the vendor's A:H.

3.1 AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
4.0 AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N

Primary rating from Vendor (CPANSec).

CVSS VectorVendor: CPANSec

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

Lifecycle Timeline

2
CVSS changed
Jul 08, 2026 - 15:22 NVD
7.5 (HIGH)
CVE Published
Jul 07, 2026 - 22:12 cve.org
UNKNOWN (no severity yet)

DescriptionCVE.org

String::Util versions before 1.36 for Perl are susceptible to a regular expression denial of service.

The trim and rtrim functions stripped trailing whitespace with s/\s*$//u. Because \s* matches greedily and the $ anchor fails whenever a non-whitespace character follows the whitespace, the regex engine retries the match at each offset of a long whitespace run, producing quadratic backtracking. The fix replaces \s*$ with \s+$.

Any caller that passes untrusted input to trim or rtrim can trigger CPU exhaustion with a string containing a long run of whitespace.

Executive ViewAI

Why It Matters

String::Util Perl module versions before 1.36 contain a denial-of-service vulnerability allowing remote attackers to crash or severely degrade application performance by submitting specially crafted input to the trim or rtrim functions. Although no public exploit code has been identified, any organization using this module to process user-supplied data faces potential service unavailability. Immediate patching is required to eliminate this attack vector.

Business Impact: High
Compensating Controls

Apply vendor patch: String::Util version 1.36 and later.

Threat Intelligence Overview

EPSS Score
0.2%
Top 91% exploitable
Prevalence
Low
niche Perl CPAN utility module; limited, declining enterprise footprint
Social Media
2
Sightings
Data Quality
7 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment CIRCL GitHub VulDB

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 HIGH
CISA KEV No
Public POC No
EPSS 0.2%
Patch available Yes
Active threat No
Deciding rule
HIGH severity (CVSS 7.0-8.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
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
Yes
Human Impact
High
Technical Impact
Partial

Priority Score

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

Attack Technique

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

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