Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2026-110756 Overview
CVE-2026-110756 affects Text::CSV_XS versions before 1.65 for Perl. The module drops the end of a record and its line ending when a UTF-8 flagged field precedes invalid UTF-8 bytes during a print operation. The print function holds back trailing bytes that are not valid UTF-8 at each buffer flush so a character split across flushes can complete. Nothing writes the held-back bytes after the record's final flush. The combine function is not affected.
Critical Impact
Output records can silently merge or become unparseable, causing downstream data corruption. A missing closing quote causes readers to absorb subsequent records into the broken field.
Affected Products
- Text::CSV_XS for Perl versions prior to 1.65
- Perl applications using Text::CSV_XSprint with UTF-8 flagged strings
- Data pipelines producing CSV output with mixed UTF-8 and binary content
Discovery Timeline
- 2026-10-16 - CVE-2026-110756 published to the National Vulnerability Database (NVD)
- 2026-10-20 - Last updated in NVD database
Technical Details for CVE-2026-110756
Vulnerability Analysis
The defect sits in the print output path of Text::CSV_XS. When writing a record that contains a UTF-8 flagged field, the module buffers output and flushes it to the destination filehandle in chunks. To avoid splitting a multi-byte UTF-8 character across two writes, print holds back trailing bytes at each flush that do not yet form a valid UTF-8 sequence. Those bytes are expected to be completed and emitted on the next flush.
The fault occurs at the final flush of a record. No code path writes the held-back bytes after the last flush completes. A record whose last field ends in such a byte loses that byte, any closing quote, and the trailing line ending. The print call still returns true, giving callers no signal that output was truncated.
The consequence is a silent integrity failure classified as [CWE-116] Improper Encoding or Escaping of Output. The next record is written onto the same physical line as the truncated record. When the truncated field was quoted, the missing closing quote causes any CSV reader to consume all following records as part of that single field until it finds a matching quote.
Root Cause
The Combine routine in CSV_XS.xs invoked Print once per record and returned without checking whether bytes remained saved for UTF-8 completion. The saved-byte buffer persisted across record boundaries but was never flushed as raw bytes at end-of-record.
Attack Vector
An attacker who can influence any field written through print with UTF-8 flagged content and a trailing invalid UTF-8 byte can corrupt all subsequent output. In applications that export user-controlled data to CSV for downstream ingestion, this enables record injection, field smuggling, or denial-of-parsing against consumers.
while (len--)
CSV_PUT (csv, dst, *ptr++);
}
- if (csv->used)
- return Print (csv, dst);
+ if (csv->used) {
+ unless (Print (csv, dst))
+ return FALSE;
+ if (csv->used) {
+ /* Print () held back trailing bytes that are not valid UTF-8
+ * to complete them on the next flush. This was the last flush
+ * of the record, so write them now, as they are */
+ int r, utf8 = csv->utf8;
+ csv->utf8 = 0;
+ r = Print (csv, dst);
+ csv->utf8 = utf8;
+ return r;
+ }
+ }
return TRUE;
} /* Combine */
Source: GitHub Patch Commit 0610a8d
Detection Methods for CVE-2026-110756
Indicators of Compromise
- CSV output files where two logical records appear concatenated on the same physical line without a separator
- Quoted fields in CSV output that span many lines unexpectedly, indicating a missing closing quote
- Downstream CSV parsers reporting unterminated string literals or field-count mismatches on files that previously parsed cleanly
Detection Strategies
- Audit Perl applications and modules for dependencies on Text::CSV_XS with version less than 1.65 using cpanm --info Text::CSV_XS or perl -MText::CSV_XS -e 'print $Text::CSV_XS::VERSION'
- Run integrity checks on recently produced CSV exports by counting records and comparing against expected row counts from source databases
- Compare byte-level output of regenerated CSV files against archived copies to detect truncated records
Monitoring Recommendations
- Add file-integrity monitoring to CSV export directories to flag unexpected size reductions
- Instrument CSV writer code paths to validate that the final byte of each emitted record is a line terminator
- Log and alert on parser errors from downstream consumers that ingest CSV produced by Perl pipelines
How to Mitigate CVE-2026-110756
Immediate Actions Required
- Upgrade Text::CSV_XS to version 1.65 or later across all Perl environments
- Identify every pipeline that uses Text::CSV_XSprint on UTF-8 flagged data and verify output integrity for recent runs
- Rebuild and redistribute any CSV artifacts generated with vulnerable versions where data integrity matters
Patch Information
The fix is included in Text::CSV_XS 1.65. The patch modifies Combine () in CSV_XS.xs to call Print a second time with the UTF-8 flag cleared, flushing any held-back bytes at the end of a record. See the MetaCPAN Release Changes and the GitHub Patch Commit for details.
Workarounds
- Use the combine method followed by direct filehandle writes instead of print, since combine is not affected
- Explicitly decode and re-encode fields to byte strings with Encode::encode('UTF-8', $field) before passing them to print, removing the UTF-8 flag
- Validate that each written record ends with the expected line terminator by reading back the output stream when feasible
# Upgrade Text::CSV_XS to the patched release
cpanm Text::CSV_XS@1.65
# Verify installed version
perl -MText::CSV_XS -e 'print "$Text::CSV_XS::VERSION\n"'
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

