A Leader in the 2026 Gartner® Magic Quadrant™ for Endpoint Protection. Six years running.Six years. Gartner® Magic Quadrant™ Leader.Find Out Why
Experiencing a Breach?Blog
Get StartedContact Us
SentinelOne
  • Platform
    Platform Overview
    • Singularity Platform
      Welcome to Integrated Enterprise Security
    • AI for Security
      Leading the Way in AI-Powered Security Solutions
    • Securing AI
      Accelerate AI Adoption with Secure AI Tools, Apps, and Agents.
    • How It Works
      The Singularity XDR Difference
    • Singularity Marketplace
      One-Click Integrations to Unlock the Power of XDR
    • Pricing & Packaging
      Comparisons and Guidance at a Glance
    Data & AI
    • Purple AI
      Accelerate SecOps with Generative AI
    • Singularity Hyperautomation
      Easily Automate Security Processes
    • AI-SIEM
      The AI SIEM for the Autonomous SOC
    • AI Data Pipelines
      Security Data Pipeline for AI SIEM and Data Optimization
    • Singularity Data Lake
      AI-Powered, Unified Data Lake
    • Singularity Data Lake for Log Analytics
      Seamlessly Ingest Data from On-Prem, Cloud or Hybrid Environments
    Endpoint Security
    • Singularity Endpoint
      Autonomous Prevention, Detection, and Response
    • Singularity XDR
      Native & Open Protection, Detection, and Response
    • Singularity RemoteOps Forensics
      Orchestrate Forensics at Scale
    • Singularity Threat Intelligence
      Comprehensive Adversary Intelligence
    • Singularity Vulnerability Management
      Application & OS Vulnerability Management
    • Singularity Identity
      Identity Threat Detection and Response
    Cloud Security
    • Singularity Cloud Security
      Block Attacks with an AI-Powered CNAPP
    • Singularity Cloud Native Security
      Secure Cloud and Development Resources
    • Singularity Cloud Workload Security
      Real-Time Cloud Workload Protection Platform
    • Singularity Cloud Data Security
      AI-Powered Threat Detection for Cloud Storage
    • Singularity Cloud Security Posture Management
      Detect and Remediate Cloud Misconfigurations
    Securing AI
    • Prompt Security
      Secure AI Tools Across Your Enterprise
  • Why SentinelOne?
    Why SentinelOne?
    • Why SentinelOne?
      Cybersecurity Built for What’s Next
    • Our Customers
      Trusted by the World’s Leading Enterprises
    • Industry Recognition
      Tested and Proven by the Experts
    • About Us
      The Industry Leader in Autonomous Cybersecurity
    Compare SentinelOne
    • Arctic Wolf
    • Broadcom
    • CrowdStrike
    • Cybereason
    • Microsoft
    • Palo Alto Networks
    • Sophos
    • Splunk
    • Trellix
    • Trend Micro
    • Wiz
    Verticals
    • Energy
    • Federal Government
    • Finance
    • Healthcare
    • Higher Education
    • K-12 Education
    • Manufacturing
    • Retail
    • State and Local Government
  • Services
    Managed Services
    • Managed Services Overview
      Wayfinder Threat Detection & Response
    • Threat Hunting
      World-Class Expertise and Threat Intelligence
    • Managed Detection & Response
      24/7/365 Expert MDR Across Your Entire Environment
    • Incident Readiness & Response
      DFIR, Breach Readiness, & Compromise Assessments
    Support, Deployment, & Health
    • Technical Account Management
      Customer Success with Personalized Service
    • SentinelOne GO
      Guided Onboarding & Deployment Advisory
    • SentinelOne University
      Live and On-Demand Training
    • Services Overview
      Comprehensive Solutions for Seamless Security Operations
    • SentinelOne Community
      Community Login
  • Partners
    Our Network
    • MSSP Partners
      Succeed Faster with SentinelOne
    • Singularity Marketplace
      Extend the Power of S1 Technology
    • Cyber Risk Partners
      Enlist Pro Response and Advisory Teams
    • Technology Alliances
      Integrated, Enterprise-Scale Solutions
    • SentinelOne for AWS
      Hosted in AWS Regions Around the World
    • Channel Partners
      Deliver the Right Solutions, Together
    • SentinelOne for Google Cloud
      Unified, Autonomous Security Giving Defenders the Advantage at Global Scale
    • Partner Locator
      Your Go-to Source for Our Top Partners in Your Region
    Partner Portal→
  • Resources
    Resource Center
    • Case Studies
    • Data Sheets
    • eBooks
    • Reports
    • Videos
    • Webinars
    • Whitepapers
    • Events
    View All Resources→
    Blog
    • Feature Spotlight
    • For CISO/CIO
    • From the Front Lines
    • Identity
    • Cloud
    • macOS
    • SentinelOne Blog
    Blog→
    Tech Resources
    • SentinelLABS
    • Ransomware Anthology
    • Cybersecurity 101
  • About
    About SentinelOne
    • About SentinelOne
      The Industry Leader in Cybersecurity
    • Investor Relations
      Financial Information & Events
    • SentinelLABS
      Threat Research for the Modern Threat Hunter
    • Careers
      The Latest Job Opportunities
    • Press & News
      Company Announcements
    • Cybersecurity Blog
      The Latest Cybersecurity Threats, News, & More
    • FAQ
      Get Answers to Our Most Frequently Asked Questions
    • DataSet
      The Live Data Platform
    • S Foundation
      Securing a Safer Future for All
    • S Ventures
      Investing in the Next Generation of Security, Data and AI
  • Pricing
Get StartedContact Us
CVE Vulnerability Database
Vulnerability Database/CVE-2026-8376

CVE-2026-8376: Perl Buffer Overflow Vulnerability

CVE-2026-8376 is a heap buffer overflow vulnerability in Perl versions through 5.43.10 affecting 32-bit builds during regex compilation. This post covers technical details, affected versions, impact, and mitigation.

Published: May 28, 2026

CVE-2026-8376 Overview

CVE-2026-8376 is a heap buffer overflow in Perl versions through 5.43.10 affecting 32-bit builds. The flaw resides in Perl_study_chunk within regcomp_study.c, where the regex compiler measures the joined substring buffer in characters instead of bytes. When a quantified fixed substring uses a large minimum count, the byte length mincount * l overflows SSize_t, leading to an undersized SvGROW allocation. The subsequent copy writes past the end of the heap buffer.

Any application compiling an attacker-controlled regular expression on a 32-bit Perl build triggers the overflow at compile time. The weakness is categorized as [CWE-680] (Integer Overflow to Buffer Overflow).

Critical Impact

Attackers who supply a crafted regular expression to a 32-bit Perl process can corrupt heap memory at compile time, enabling potential remote code execution or denial of service.

Affected Products

  • Perl 5.x through 5.43.10 (32-bit builds)
  • Applications embedding 32-bit perl that compile untrusted regular expressions
  • Web applications, CGI scripts, and tooling running on 32-bit Perl interpreters

Discovery Timeline

  • 2026-05-26 - CVE-2026-8376 published to NVD
  • 2026-05-26 - Public disclosure on the OpenWall OSS Security mailing list
  • 2026-05-27 - Last updated in NVD database

Technical Details for CVE-2026-8376

Vulnerability Analysis

The vulnerability lives in Perl's regex study optimization phase. Perl_study_chunk joins quantified fixed substrings to optimize pattern matching. The original code computed the required buffer size using character counts, then multiplied mincount by the per-character length l without checking for integer overflow on 32-bit SSize_t.

For patterns such as /\x{10000}{1073741824}/, the product mincount * l exceeds SSize_t_MAX on a 32-bit build. The truncated result is passed to SvGROW, which allocates a buffer far smaller than the actual data that follows. The subsequent string copy then writes well past the allocation boundary, corrupting adjacent heap structures.

Root Cause

The root cause is an integer overflow that is later promoted to a heap buffer overflow [CWE-680]. The size calculation in regcomp_study.c used character-based arithmetic rather than byte-based arithmetic, and lacked bounds checks against SSize_t_MAX before computing the allocation size.

Attack Vector

Exploitation requires the attacker to control a regular expression compiled by a 32-bit Perl interpreter. This pattern is common in CGI handlers, log parsers, web frameworks, and any tooling that accepts user-supplied regex input. The flaw triggers at regex compile time, so the attacker does not need the pattern to match anything.

c
                                                (U8 *) SvEND(data->last_found))
                                 - (U8*)s;
                         l -= old;
+
+                        if (l > 0 &&
+                            (mincount >= SSize_t_MAX / (SSize_t)l
+                             || old > SSize_t_MAX - mincount * (SSize_t)l)) {
+                            FAIL("Regexp out of space");
+                        }
+
                         /* Get the added string: */
                         last_str = newSVpvn_utf8(s  + old, l, UTF);
                         last_chrs = UTF ? utf8_length((U8*)(s + old),

Source: Perl5 commit 5e7f119eb2bb. The patch adds explicit overflow checks against SSize_t_MAX before the allocation and fails the regex compilation with Regexp out of space when the size would wrap.

Detection Methods for CVE-2026-8376

Indicators of Compromise

  • Perl interpreter crashes or segmentation faults during regex compilation on 32-bit hosts
  • Error messages referencing Regexp out of space after applying the patch, indicating attempted exploitation
  • Anomalous regex patterns containing very large quantifier counts such as {1073741824} in inbound request data or logs

Detection Strategies

  • Inventory all Perl installations across the environment and identify 32-bit builds using perl -V:ptrsize where ptrsize=4 indicates a vulnerable target architecture
  • Inspect web server, CGI, and application logs for user-supplied regular expressions containing large repetition counts or unusual Unicode codepoint sequences
  • Correlate Perl process crash events with preceding HTTP requests or input that contained regex-like payloads

Monitoring Recommendations

  • Enable core dump collection on hosts running 32-bit Perl to capture exploitation attempts for forensic analysis
  • Monitor for unexpected child process termination of perl, httpd, or other interpreters embedding Perl
  • Alert on application error logs containing Regexp out of space or heap corruption signatures from glibc such as malloc(): corrupted messages

How to Mitigate CVE-2026-8376

Immediate Actions Required

  • Apply the upstream Perl patch from commit 5e7f119eb2bb1181be908701f22bf7068e722f1c or upgrade to a Perl release that includes the fix
  • Audit all code paths that compile regular expressions from untrusted sources and add input validation for quantifier ranges
  • Where feasible, migrate 32-bit Perl deployments to 64-bit builds, which are not affected by the integer overflow

Patch Information

The fix is committed upstream in the Perl5 repository. See the Perl5 security patch for the change to regcomp_study.c. The patch validates that mincount * l cannot overflow SSize_t_MAX before allocation and emits a Regexp out of space compile-time error when the bound would be exceeded. Distributors including the OpenWall community have tracked the issue via the OpenWall OSS Security advisory.

Workarounds

  • Restrict user-supplied regular expression input by rejecting patterns containing large quantifier values before passing them to qr// or m//
  • Run Perl workloads on 64-bit operating systems and interpreters until patched packages are deployed
  • Sandbox CGI and web handlers that compile dynamic regexes using process isolation or resource limits to contain heap corruption
bash
# Verify Perl pointer size and version on each host
perl -V:ptrsize -V:version

# Example regex input filter applied before compilation
perl -e 'my $re = $ARGV[0];
         die "rejected: quantifier too large\n"
             if $re =~ /\{\s*(\d{6,})\s*\}/;
         qr/$re/;' "$USER_REGEX"

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

  • Vulnerability Details
  • TypeBuffer Overflow

  • Vendor/TechPerl

  • SeverityCRITICAL

  • CVSS Score9.8

  • EPSS Probability0.04%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityNone
  • AvailabilityHigh
  • CWE References
  • CWE-680
  • Technical References
  • OpenWall OSS Security Mailing List
  • Vendor Resources
  • GitHub Perl Commit Patch
  • Related CVEs
  • CVE-2026-8796: Sereal::Decoder Buffer Overflow Flaw

  • CVE-2023-47038: Perl Buffer Overflow Vulnerability

  • CVE-2020-12723: Perl Buffer Overflow Vulnerability

  • CVE-2020-10543: Perl Buffer Overflow Vulnerability
Default Legacy - Prefooter | Experience the World’s Most Advanced Cybersecurity Platform

Experience the Most Advanced Cybersecurity Platform

See how the world’s most intelligent, autonomous cybersecurity platform can protect your organization today and into the future.

Try SentinelOne
  • Get Started
  • Get a Demo
  • Product Tour
  • Why SentinelOne
  • Pricing & Packaging
  • FAQ
  • Contact
  • Contact Us
  • Customer Support
  • SentinelOne Status
  • Language
  • Platform
  • Singularity Platform
  • Singularity Endpoint
  • Singularity Cloud
  • Singularity AI-SIEM
  • Singularity Identity
  • Singularity Marketplace
  • Purple AI
  • Services
  • Wayfinder TDR
  • SentinelOne GO
  • Technical Account Management
  • Support Services
  • Verticals
  • Energy
  • Federal Government
  • Finance
  • Healthcare
  • Higher Education
  • K-12 Education
  • Manufacturing
  • Retail
  • State and Local Government
  • Cybersecurity for SMB
  • Resources
  • Blog
  • Labs
  • Case Studies
  • Videos
  • Product Tours
  • Events
  • Cybersecurity 101
  • eBooks
  • Webinars
  • Whitepapers
  • Press
  • News
  • Ransomware Anthology
  • Company
  • About Us
  • Our Customers
  • Careers
  • Partners
  • Legal & Compliance
  • Security & Compliance
  • Investor Relations
  • S Foundation
  • S Ventures

©2026 SentinelOne, All Rights Reserved.

Privacy Notice Terms of Use

English