Skip to main content

ExtUtils-Typemaps-Default EUVDEUVD-2026-96314

| CVE-2026-107373 CRITICAL
Out-of-bounds Read (CWE-125)
2026-10-10 CPANSec GHSA-g3mm-4ggm-mrv5
9.1
CVSS 3.1 · Vendor: CPANSec
View

Attack ChainAIDerived

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

  1. Access
    Reach XS function expecting std::string
  2. Delivery
    Supply non-string SV (int/ref)
  3. Exploit
    SvCUR evaluated before stringify yields bad length
  4. Execution
    std::string copies out-of-bounds heap bytes
  5. Impact
    Process abort/segfault or memory leak

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Bounds checking, read limits
MITRE ATT&CK

1 technique across 1 tactic: Collection

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

Exploitation Conditions

Requires a downstream XS/C++ module built against ExtUtils::Typemaps::STL::String before 1.06 that actually uses the T_STD_STRING INPUT typemap, compiled by a C++ toolchain whose generated code evaluates SvCUR($arg) before SvPV_nolen($arg) (an unspecified, compiler-dependent ordering), AND a code path that passes a non-string Perl SV (integer, number, or reference) into the std::string conversion. Limiting factors: builds using compilers that evaluate left-to-right are unaffected; the bug cannot trigger unless the typemap is used and non-string input reaches it; impact beyond crash (information disclosure) is not guaranteed. This is not a flaw in a running service by default but a defect compiled into derivative XS modules.

Impact

Signals conflict sharply and should temper the headline 9.1. The input CVSS vector (AV:N/AC:L/PR:N/UI:N, C:H/A:H) implies a trivially remotely exploitable critical flaw, but the description describes a compiler-dependent C++ argument-evaluation-order bug in a Perl XS typemap that manifests only when a non-string SV is passed, producing an invalid SvCUR length. This is far more constrained than AC:L suggests: exploitation requires a downstream application to actually use the ExtUtils::Typemaps::STL::String T_STD_STRING typemap AND be compiled by a toolchain that evaluates SvCUR($arg) before SvPV_nolen($arg) AND route attacker-controlled non-string data into that conversion - none of which is guaranteed. CWE-125 (out-of-bounds read) and the primary described outcome ('abort or segfault') point to availability as the dominant, reliable impact, while the C:H rating depends on the OOB std::string copy leaking adjacent heap memory, which is plausible but conditional and not demonstrated. Corroborating real-risk signals are weak: EPSS is 0.19% (8th percentile), there is no CISA KEV listing, and no public exploit is identified. Net assessment: this is a legitimate memory-safety defect worth patching in affected build pipelines, but it is a high-CVSS/low-real-world-risk item for most organizations rather than an urgent widespread threat - the AC:L and C:H metrics appear optimistic given the compiler- and configuration-dependent trigger.

Exploit ScenarioDerived

An application exposing a Perl/XS interface built with the vulnerable typemap (pre-1.06) receives an attacker-supplied non-string value - an integer, number, or reference - where a std::string argument is expected. On a C++ compiler whose codegen evaluates SvCUR($arg) before SvPV_nolen($arg), the std::string is constructed with a stale/invalid length and copies out-of-bounds heap memory, causing a segfault/denial of service or potentially leaking adjacent memory. No public exploit code exists at time of analysis.

Act Now Prioritize within 24-48h. Why: CRITICAL severity.
No patch listed yet 0.2% exploitation probability (EPSS)

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

Alert me

AnalysisAIv1 – Oct 16, 2026

An out-of-bounds read in the T_STD_STRING typemap shipped with ExtUtils-Typemaps-Default before 1.06 causes the generated C++ conversion to evaluate SvCUR($arg) before stringifying the argument, so a derived XS/C++ module that passes a non-string Perl scalar (integer, number, or reference) into the std::string conversion can read an invalid length and abort or segfault the process. The defect is not present in a running service by default but is compiled into derivative XS modules, and it only triggers when the build toolchain's unspecified argument-evaluation order happens to evaluate the length macro first, so exposure is conditional rather than universal. The headline CVSS 9.1 conflicts sharply with the authoritative assessment (AC:H, C:L/A:H) and a very low EPSS of 0.19% (8th percentile); no public exploit code was identified at time of analysis.

RemediationAI

The primary fix is to upgrade ExtUtils-Typemaps-Default to version 1.06, which is the first release containing the corrected T_STD_STRING typemap (per the metacpan changelog) and corresponds to upstream commit a6b9c298b34ddadc582961403e715d292f82a22d, which replaces SvPV_nolen/SvCUR with a single SvPV($arg, len) call - vendor-released patch: ExtUtils-Typemaps-Default 1.06. Because the defective argument ordering is code-generated and compiled into consuming modules, upgrading the typemap distribution alone is insufficient: every downstream XS/C++ distribution that uses T_STD_STRING must be rebuilt and reinstalled against the patched typemap so that regenerated C++ picks up the safe conversion; otherwise previously compiled binaries retain the flaw. Where immediate rebuilds are impractical, compensating controls are limited and should be understood as risk reduction rather than a fix: (1) audit and harden XS code paths so that only genuine string scalars reach T_STD_STRING, for example by checking SvPOK or explicitly stringifying with SvPV before the conversion - this prevents the out-of-bounds read but requires source changes in each XS module and will not protect paths that legitimately accept numeric or reference input; (2) avoid using the affected typemap entirely and hand-write the std::string conversion, at the cost of divergence from upstream and ongoing maintenance; (3) pin builds to a C++ compiler whose observed argument-evaluation order is left-to-right, which is a fragile, toolchain-dependent mitigation that offers no guarantee across compiler versions or optimization levels and does not address the underlying undefined behavior. Advisory and tracking details are available at https://seclists.org/oss-sec/2026/q4/130, https://rt.cpan.org/Public/Bug/Display.html?id=94110, and EUVD-2026-96314; detection should prioritize CPAN installations of ExtUtils-Typemaps-Default below 1.06 and any XS distributions compiled with the pre-1.06 typemap.

Affected ProductsAI

ExtUtils::Typemaps::STL::String versions before 1.06, distributed as part of the ExtUtils-Typemaps-Default CPAN distribution (maintained by SMUELLER), are affected; the T_STD_STRING INPUT typemap is the vulnerable component. The practical blast radius extends to any downstream XS/C++ Perl distribution that consumed the affected typemap and was compiled into a binary module, since the flawed argument ordering is baked into generated C++ at build time. Vendor references include the 1.06 changelog at https://metacpan.org/release/SMUELLER/ExtUtils-Typemaps-Default-1.06/changes, the fixing commit at https://github.com/tsee/extutils-typemap-default/commit/a6b9c298b34ddadc582961403e715d292f82a22d, the original RT ticket at https://rt.cpan.org/Public/Bug/Display.html?id=94110, the CPANSec report mirrored at https://seclists.org/oss-sec/2026/q4/130, and EUVD record EUVD-2026-96314 (https://nvd.nist.gov/vuln/detail/CVE-2026-107373). No CPE strings were supplied in the input data, so exact platform/version enumeration beyond the CPAN version range cannot be confirmed.

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

The flaw lives in the Perl XS typemap machinery, specifically the T_STD_STRING INPUT typemap in ExtUtils::Typemaps::STL::String (part of the ExtUtils-Typemaps-Default distribution). The original template was $var = std::string( SvPV_nolen( $arg ), SvCUR( $arg ) );, which mixes two Perl C API macros: SvPV_nolen() returns a pointer to the scalar's string buffer (forcing stringification as a side effect), while SvCUR() returns the length of the scalar's current PV buffer without forcing stringification. C++ does not specify the order in which function-call arguments are evaluated, so a compiler is free to evaluate SvCUR($arg) first; when $arg is an IV, NV, or RV rather than a PV, SvCUR reads the scalar's length field before it has been populated with a string value, yielding a bogus length. Constructing std::string with that attacker-influenced length reads beyond the actual buffer, which maps to CWE-125 (Out-of-Bounds Read) and is tagged as both buffer overflow and information disclosure, with the practical outcome ranging from an abort/segfault (availability) to possible leakage of adjacent memory into the resulting std::string (confidentiality). The upstream fix (commit a6b9c298b34ddadc582961403e715d292f82a22d) replaces both the scalar and the new std::string variants with size_t len; const char * c = SvPV($arg, len); $var = std::string(c, len);, which obtains pointer and length atomically from a single macro and eliminates the ordering dependency. The conditional, compiler-dependent nature of the trigger is why the independent assessment assigns AC:H rather than AC:L, and why the network-vector 9.1 base score overstates real-world exposure for what is fundamentally a build-time defect in downstream XS code. Note that the reference list cross-cites CVE-2026-80490, suggesting a related or duplicated record in the same CPAN/Perl typemap area.

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

Compiler- and input-dependent trigger (non-string SV plus specific evaluation order) justifies AC:H; crash/DoS is the reliable impact (A:H) while OOB heap read gives only limited, conditional disclosure (C:L).

3.1 AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:N/A:H
4.0 AV:N/AC:H/AT:N/PR:N/UI:N/VC:L/VI:N/VA:H/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
High
Integrity
None
Availability
High

Lifecycle Timeline

3
CVSS changed
Oct 16, 2026 - 16:24 NVD
9.1 (CRITICAL)
CVE Published
Oct 10, 2026 - 12:44 cve.org
CRITICAL 9.1
CVE Published
Oct 10, 2026 - 12:44 cve.org
UNKNOWN (no severity yet)

DescriptionCVE.org

ExtUtils::Typemaps::STL::String versions before 1.06 for Perl T_STD_STRING typemap may read the SV length before stringifying the argument.

The typemap uses

$var = std::string( SvPV_nolen($arg), SvCUR($arg) )

However, evaluation order for C++ arguments is not specified, and some compilers may produce code that evalutes SvCUR($arg) first.

When $arg is not a string (for example, an interger, number or a reference) then SvCUR will return an invalid value, and the program may abort or segfault.

Executive ViewAI

Why It Matters

ExtUtils-Typemaps-Default, a build-time Perl toolchain component used to generate C++ string conversions in XS modules, contains an out-of-bounds read that is compiled into any derived module which passes a non-string Perl value (integer, number, or reference) into a std::string conversion, allowing that process to abort or crash. Because the defect is embedded in downstream compiled modules rather than running by default, exposure is conditional and limited to the specific products and services our teams have built with this toolchain - but an abort in one of those services is a denial-of-service an attacker could potentially provoke with a crafted non-string argument. Leadership should care because remediation requires rebuilding our own compiled Perl dependencies rather than routine patching, and no vendor-released patch was identified at time of analysis.

Business Impact: Medium
Compensating Controls

No vendor-released patch identified at time of analysis; interim mitigations are build-time and code-level. Force explicit stringification of arguments at the XS boundary (convert scalars via SvPV or explicit string interpolation) so a non-string scalar can never reach the length macro, restrict which derived modules accept integer, number, or reference arguments into std::string conversions, and block untrusted input from reaching those conversions. Adopt ExtUtils-Typemaps-Default 1.06 or later in build images as soon as it is obtainable and rebuild downstream XS modules, since the advisory names 1.06 as the version where the defect is absent. Pause or isolate builds using the affected typemap, monitor affected services for aborts and segfaults, and maintain an inventory of affected builds to enable rapid rebuild once a fixed toolchain release is confirmed.

Threat Intelligence Overview

EPSS Score
0.2%
Top 92% exploitable
Prevalence
Low
niche CPAN XS typemap helper for Perl-to-C++ string bindings
Social Media
3
Sightings
Data Quality
5 sources
Confidence: Medium

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 CRITICAL
CISA KEV No
Public POC No
EPSS 0.2%
Patch available No
Active threat No
Deciding rule
CRITICAL severity
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

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

Attack Technique

A buffer overflow occurs when a program writes more data to a memory buffer than it was allocated to hold, causing the excess data to spill into adjacent memory regions.

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-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

CVE-2015-8853 HIGH
7.5 May 25

The (1) S_reghop3, (2) S_reghop4, and (3) S_reghopmaybe3 functions in regexec.c in Perl before 5.24.0 allow context-depe

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