Skip to content
Heist/ feed
Back to feed
High

Text::CSV_XS versions before 1.62 for Perl have a use-after-free when registered callbacks extend the Perl argument stack, which may enable type confusion or memory corruption

Type: advisorySources: OSV

Text::CSV_XS versions before 1.62 for Perl have a use-after-free when registered callbacks extend the Perl argument stack, which may enable type confusion or memory corruption. The Parse, print, getline, and getline_all methods invoke registered callbacks (for example after_parse, before_print, or on_error) and cache the Perl argument stack pointer across the call. If a callback extends the argument stack enough to trigger a reallocation, the return value is written through the stale pointer into the freed buffer, and the caller reads the original $self argument as the return value instead. Calling code that expects parsed data from getline_all receives the Text::CSV_XS object in its place, leading to logic errors or crashes. Text::CSV_XS objects used without any registered callbacks are not affected.

Products
Not specified
Affected versions
Not specified
Fixed versions
Not specified
CVEs
CVE-2026-7111
Confirmed fixed CVEs
Not specified
Updated in this feed
2 Nov 2026, 17:11 UTC · Revision 1

Source evidence

Text::CSV_XS versions before 1.62 for Perl have a use-after-free when registered callbacks extend the Perl argument stack, which may enable type confusion or memory corruption

core-osv · Original source

Published 29 Apr 2026, 14:22 UTC

Text::CSV_XS versions before 1.62 for Perl have a use-after-free when registered callbacks extend the Perl argument stack, which may enable type confusion or memory corruption. The Parse, print, getline, and getline_all methods invoke registered callbacks (for example after_parse, before_print, or on_error) and cache the Perl argument stack pointer across the call. If a callback extends the argument stack enough to trigger a reallocation, the return value is written through the stale pointer into the freed buffer, and the caller reads the original $self argument as the return value instead. Calling code that expects parsed data from getline_all receives the Text::CSV_XS object in its place, leading to logic errors or crashes. Text::CSV_XS objects used without any registered callbacks are not affected.

osv:CVE-2026-7111
Complete source record
{
  "id": "3047085558204030e87eb5e2e018c6f529261eaeb279515f6b4f757cde691f4f",
  "url": "https://osv.dev/vulnerability/CVE-2026-7111",
  "method": "structured",
  "payload": {
    "kind": "advisory",
    "title": "Text::CSV_XS versions before 1.62 for Perl have a use-after-free when registered callbacks extend the Perl argument stack, which may enable type confusion or memory corruption",
    "summary": "Text::CSV_XS versions before 1.62 for Perl have a use-after-free when registered callbacks extend the Perl argument stack, which may enable type confusion or memory corruption. The Parse, print, getline, and getline_all methods invoke registered callbacks (for example after_parse, before_print, or on_error) and cache the Perl argument stack pointer across the call. If a callback extends the argument stack enough to trigger a reallocation, the return value is written through the stale pointer into the freed buffer, and the caller reads the original $self argument as the return value instead. Calling code that expects parsed data from getline_all receives the Text::CSV_XS object in its place, leading to logic errors or crashes. Text::CSV_XS objects used without any registered callbacks are not affected.",
    "evidence": "osv:CVE-2026-7111",
    "products": [],
    "severity": "high",
    "structured": {
      "id": "CVE-2026-7111",
      "aliases": [
        "CVE-2026-7111"
      ],
      "metrics": [
        {
          "type": "CVSS_V3",
          "score": "CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H"
        }
      ],
      "affected": [
        {
          "ranges": [
            {
              "repo": "https://github.com/cpan-authors/text-csv_xs",
              "type": "GIT",
              "events": [
                {
                  "introduced": "0"
                },
                {
                  "fixed": "4e8d5cb50a4063569a3974a15da94851d8cfa5d9"
                },
                {
                  "fixed": "c17f31a5f2bf36674748eb4b6e25672f0571a224"
                }
              ],
              "database_specific": {
                "extracted_events": [
                  {
                    "cpe": "cpe:2.3:a:hmbrand:text\\:\\:csv_xs:*:*:*:*:*:perl:*:*",
                    "range": [
                      {
                        "introduced": "0"
                      },
                      {
                        "fixed": "1.62"
                      }
                    ],
                    "source": "CPE_RANGE"
                  },
                  {
                    "range": [
                      {
                        "fixed": "c17f31a5f2bf36674748eb4b6e25672f0571a224"
                      }
                    ],
                    "source": "REFERENCES_COMMIT"
                  }
                ]
              }
            }
          ],
          "versions": [
            "1.61",
            "1.60",
            "1.59",
            "1.58",
            "1.56",
            "1.55",
            "1.54",
            "1.53",
            "1.51",
            "1.50",
            "1.49",
            "1.48",
            "1.47",
            "1.46",
            "1.45",
            "1.44",
            "1.43",
            "1.42",
            "1.41",
            "1.40",
            "1.39",
            "1.38",
            "1.37",
            "1.36",
            "1.35",
            "1.34",
            "1.33",
            "1.32",
            "1.31",
            "1.30",
            "1.29",
            "1.28",
            "1.27",
            "1.26",
            "1.25",
            "1.24",
            "1.23",
            "1.22",
            "1.21",
            "1.20",
            "1.19",
            "1.18",
            "1.17",
            "1.16",
            "1.15",
            "1.14",
            "1.13",
            "1.12",
            "1.11",
            "1.10",
            "1.09",
            "1.08",
            "1.07",
            "1.06",
            "1.05",
            "1.04",
            "1.03",
            "1.02",
            "1.01",
            "1.00",
            "0.99",
            "0.98",
            "0.97",
            "0.96",
            "0.95",
            "0.94",
            "0.93",
            "0.92",
            "0.91",
            "0.90",
            "0.88",
            "0.87",
            "0.86",
            "0.85",
            "0.84",
            "0.83",
            "0.82",
            "0.81",
            "0.80",
            "0.79",
            "0.78",
            "0.77",
            "0.76",
            "0.75",
            "0.74",
            "0.73",
            "0.72",
            "0.71",
            "0.70",
            "0.69",
            "0.68",
            "0.67",
            "0.66",
            "0.65",
            "0.64",
            "0.63",
            "0.62",
            "0.61",
            "0.60",
            "0.59",
            "0.58",
            "0.57",
            "0.56",
            "0.55",
            "0.54",
            "0.53",
            "0.52",
            "0.51",
            "0.50",
            "0.46",
            "0.45",
            "0.44",
            "0.43",
            "0.42",
            "0.41",
            "0.40",
            "0.37",
            "0.36",
            "0.35-Valloire",
            "0.34",
            "0.33"
          ],
          "database_specific": {
            "source": "https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-7111.json"
          }
        }
      ],
      "modified": "2026-10-28T02:30:21.780938480Z",
      "provider": "osv",
      "references": [
        "https://cpan.org/modules",
        "https://lists.debian.org/debian-lts-announce/2026/06/msg00037.html",
        "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/7xxx/CVE-2026-7111.json",
        "https://metacpan.org/release/HMBRAND/Text-CSV_XS-1.62/changes",
        "https://nvd.nist.gov/vuln/detail/CVE-2026-7111",
        "https://github.com/cpan-authors/Text-CSV_XS/commit/c17f31a5f2bf36674748eb4b6e25672f0571a224.patch",
        "https://github.com/cpan-authors/Text-CSV_XS"
      ],
      "provider_metadata": {
        "cwe_ids": [
          "CWE-416",
          "CWE-825"
        ],
        "cna_assigner": "CPANSec",
        "osv_generated_from": "https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/7xxx/CVE-2026-7111.json"
      }
    },
    "related_cves": [
      {
        "value": "CVE-2026-7111",
        "evidence": "/id"
      }
    ],
    "security_relevant": true,
    "severity_evidence": "/severity/0/score"
  },
  "source_id": "core-osv",
  "document_id": 487568,
  "published_at": "2026-04-29T14:22:29.358+00:00"
}