Skip to main content

Text::CSV_XS EUVDEUVD-2026-103198

| CVE-2026-110758 HIGH
Buffer Under-read (CWE-127)
2026-10-16 CPANSec GHSA-fxm8-2g6q-9hhf
7.5
CVSS 3.1 · Vendor: CPANSec
View

Attack ChainAIDerived

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

  1. Access
    Submit crafted CSV with all-blank escaped field
  2. Exploit
    strip_trail_whitespace walks past field start
  3. Execution
    Read byte before heap buffer
  4. Impact
    Zero/leak adjacent heap memory or crash parser

Vulnerability Assessment

Weakness
CWE
Exploitation Conditions

Requires the application to parse attacker-influenced CSV with the non-default allow_whitespace option enabled. The vulnerable all-blank field must reach strip_trail_whitespace via one of two specific shapes: (1) an unquoted all-blank field preceded by a leading escape_char that differs from quote_char (e.g. escape_char => '\\'), or (2) a quoted field in getline whose line ends in two carriage returns ('" "\r\r\n'). Further, the byte physically preceding the field's heap buffer must itself be a space or tab for the backward walk to read/zero beyond it, making the effect allocator- and layout-dependent. Limiting factors: allow_whitespace is NOT a default setting; the trigger inputs are narrow; leading blanks are normally skipped so only these edge paths deliver an all-blank field; and the condition is reliably observable only under memory sanitizers.

Impact

Signals conflict. The NVD CVSS of 7.5 (AV:N/AC:L/PR:N/UI:N/C:H) portrays a remote, unauthenticated, high-confidentiality issue, but the technical reality is a one-byte out-of-bounds read immediately before a heap buffer (CWE-127) that triggers only when the application enables the non-default allow_whitespace option AND feeds attacker-controlled input matching narrow shapes. The C:H rating appears overstated: the out-of-bounds byte is consumed by an internal space/tab comparison (and possibly zeroed) rather than returned to the attacker, so realistic impact is a crash or marginal memory effect, not reliable data theft - the project's own test notes it 'shows under valgrind or ASan only.' Corroborating the low-priority read: EPSS is 0.19% (8th percentile), there is NO CISA KEV listing, and no public exploit was indicated. No SSVC decision data was provided in the input. Net: this is a legitimate memory-safety bug worth patching, but the combination of a non-default configuration requirement, narrow trigger conditions, very low EPSS, and absence of exploitation evidence makes it a routine-patch item rather than an emergency, despite the HIGH CVSS. Note the base score assumes the vulnerable parsing path is exposed to untrusted input with allow_whitespace enabled - a precondition the base metrics do not capture.

Exploit ScenarioDerived

An application parses untrusted CSV with Text::CSV_XS configured with allow_whitespace enabled (and, for the parse path, a custom escape_char differing from quote_char); an attacker submits input containing an all-blank field (e.g. a leading escape char followed by spaces/tabs, or a quoted blank field whose line ends in two CRs via getline), causing strip_trail_whitespace to walk backward past the field start and read the byte before the heap buffer. No public exploit was identified; given the single-byte out-of-bounds read, the practical result is most likely a crash or minor memory-state anomaly rather than controllable disclosure, and it is reliably observable only under ASan/valgrind.

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 – Oct 20, 2026

Perl's Text::CSV_XS module (versions before 1.65) contains a buffer under-read in its XS whitespace-stripping routine: when parsing an all-blank field with the non-default allow_whitespace option, cx_strip_trail_whitespace walks backwards past the start of the field's heap buffer, reading and potentially zeroing one byte before it. Reaching that path requires a specific input shape - an unquoted all-blank field preceded by an escape_char that differs from quote_char, or a quoted field in getline whose line ends in two carriage returns - and an allocator layout where the physically preceding byte is itself a space or tab, so the effect is layout-dependent and reliably observable only under valgrind/ASan. Remote unauthenticated attackers who can influence CSV input to an application that enables allow_whitespace are the exposure surface; the impact ranges from a one-byte out-of-bounds read (the CVE's information-disclosure reading, 7.5) to limited memory corruption (I:L/A:L in this independent assessment), and no public exploit code or active exploitation (CISA KEV) was identified at time of analysis, with EPSS low at 0.19% (8th percentile).

RemediationAI

Upgrade to Text::CSV_XS 1.65 or later - vendor-released patch: version 1.65, installable from CPAN (cpan HMBRAND/Text-CSV_XS-1.65.tar.gz or via cpanm/carton/your distribution package once rebuilt) - and confirm the new version with perl -MText::CSV_XS -e 'print $Text::CSV_XS::VERSION'; alternatively, back-port the one-line guard while (len && (s[len - 1] CH_SPACE || s[len - 1] CH_TAB)) from commit efed7ee21177c59a5b69e787f84154e1fcb0d095. Where upgrading is deferred, disable allow_whitespace in every Text::CSV_XS constructor and strip whitespace in application code before parsing - the trade-off is a behavioral change, since fields previously auto-trimmed will now be returned with leading/trailing blanks intact and comparisons or numeric conversions may break. A narrower stopgap is to avoid the two triggering shapes entirely by keeping escape_char equal to quote_char (or unset) and rejecting input that ends lines with CR CR, though this depends on controlling every parse call site. Validation under valgrind or AddressSanitizer only detects the under-read, it does not mitigate it, and because exploitation is allocator- and layout-dependent, absence of a crash is not evidence of safety. Patch provenance and disclosure details are at https://github.com/cpan-authors/Text-CSV_XS/commit/efed7ee21177c59a5b69e787f84154e1fcb0d095.patch, https://metacpan.org/release/HMBRAND/Text-CSV_XS-1.65/changes, and https://seclists.org/oss-sec/2026/q4/213.

Affected ProductsAI

All Text::CSV_XS releases prior to 1.65 for Perl are affected, across any OS and Perl build where the XS module is compiled and the caller uses the allow_whitespace option. Upstream release notes for the fixed 1.65 distribution are at https://metacpan.org/release/HMBRAND/Text-CSV_XS-1.65/changes, the code-level fix is the commit/patch at https://github.com/cpan-authors/Text-CSV_XS/commit/efed7ee21177c59a5b69e787f84154e1fcb0d095.patch, and the coordinated disclosure write-up from CPANSec is at https://seclists.org/oss-sec/2026/q4/213 (mirrored in ENISA EUVD as EUVD-2026-103198 and in NVD as CVE-2026-110758). Because the module is frequently bundled as a dependency rather than vendored explicitly, operators should enumerate installed versions with perl -MText::CSV_XS -e 'print $Text::CSV_XS::VERSION' across all interpreters and container images rather than assuming only direct dependencies are exposed.

Affects your stack

Find out whether the stacks and servers you run are on an affected version.

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

Technical ContextAI · show details

Text::CSV_XS is a widely deployed Perl module whose core parser is written in C as Perl XS (CSV_XS.xs compiled into a shared object), used by countless Perl applications, ETL pipelines and data-ingest scripts for CSV parsing. CWE-127 (Buffer Under-read) applies here: the helper cx_strip_trail_whitespace, which trims trailing spaces and tabs from unquoted fields when the caller enables the non-default allow_whitespace option, evaluated the loop condition s[len - 1] == CH_SPACE || ... without first checking that len was still greater than zero. For a field consisting solely of blanks the strip loop exhausts the field's own length and the index goes to -1, reading the byte immediately before the field's heap allocation; if that byte happens to be a space or tab it is zeroed and the walk continues further backwards, so the observable behavior depends entirely on what the allocator placed there. Leading blanks are normally skipped before a field is stored, which is why the bug is reachable only through narrow edge paths: an all-blank field that arrives after a leading escape_char that differs from quote_char, or a quoted field delivered by getline when its line terminates in two CR characters. The upstream fix (commit efed7ee21177c59a5b69e787f84154e1fcb0d095) is a one-line guard adding len && to that while condition, together with regression tests in t/65_allow.t covering escaped blanks and the CR-CR getline case; the ChangeLog entry reads "Under allow_whitespace, do not strip beyond field start." No CPE strings were supplied in the input, but the affected artifact is the Text::CSV_XS distribution on CPAN for any Perl platform where the XS component is built.

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

Requires non-default allow_whitespace plus narrow crafted input and specific heap layout, so AC:H; single-byte out-of-bounds read with possible backward zeroing yields at most I:L/A:L and no direct disclosure (C:N).

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

Primary rating from Vendor (CPANSec).

CVSS VectorVendor: CPANSec

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

Lifecycle Timeline

3
CVSS changed
Oct 20, 2026 - 19:22 NVD
7.5 (HIGH)
CVE Published
Oct 16, 2026 - 22:08 cve.org
UNKNOWN (no severity yet)
CVE Published
Oct 16, 2026 - 22:08 cve.org
HIGH 7.5

DescriptionCVE.org

Text::CSV_XS versions before 1.65 for Perl read before the start of an all-blank field under allow_whitespace in strip_trail_whitespace.

Under allow_whitespace, strip_trail_whitespace removes trailing spaces and tabs from each unquoted field without stopping at the start of the field. For a field of only blanks it reads the byte before the field's heap buffer. If that byte is also a space or tab, it may be zeroed and the walk continue backwards, depending on what the allocator placed there.

Leading blanks are normally skipped before a field is stored, but an all-blank field still arrives after a leading escape_char that differs from quote_char, or as a quoted field in getline when its line ends in two CRs.

Executive ViewAI

Why It Matters

Perl Text::CSV_XS versions before 1.65 contain a memory-safety weakness that can affect applications using the module to process external CSV files, with potential confidentiality and reliability consequences. No public exploit identified at time of analysis, and real-world impact depends on specific input and system layout, limiting likelihood; still, teams ingesting third-party CSV data should treat the library as a priority dependency. Leadership should care because a successful attack could expose small amounts of adjacent memory or disrupt CSV-processing services that support business data flows.

Business Impact: Medium
Compensating Controls

Apply vendor patch.

Threat Intelligence Overview

EPSS Score
0.2%
Top 92% exploitable
Prevalence
Medium
de facto Perl CSV parser, but overall Perl ecosystem is a moderate footprint
Social Media
1
Sightings
Data Quality
6 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 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· derived
Scheduled
Exploitation· derived
None
System Exposure· derived
Open
Automatable· derived
Yes
Human Impact
Medium

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

Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.

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