The SentinelOne Annual Threat Report - A Defenders Guide from the FrontlinesThe SentinelOne Annual Threat ReportGet the Report
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
    • 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-2020-7065

CVE-2020-7065: PHP Buffer Overflow Vulnerability

CVE-2020-7065 is a buffer overflow vulnerability in PHP's mb_strtolower() function affecting versions 7.3.x below 7.3.16 and 7.4.x below 7.4.4. This article covers technical details, affected versions, and mitigation.

Published: March 4, 2026

CVE-2020-7065 Overview

CVE-2020-7065 is a stack buffer overflow vulnerability in PHP's mb_strtolower() function when processing UTF-32LE encoded strings. In PHP versions 7.3.x below 7.3.16 and 7.4.x below 7.4.4, specially crafted invalid strings passed to the mb_strtolower() function with UTF-32LE encoding can cause PHP to overwrite a stack-allocated buffer. This memory corruption vulnerability can result in application crashes and potentially allow attackers to execute arbitrary code on affected systems.

Critical Impact

This stack buffer overflow vulnerability can lead to memory corruption, application crashes, and potentially remote code execution when processing malicious UTF-32LE encoded input through PHP's multibyte string functions.

Affected Products

  • PHP versions 7.3.x below 7.3.16
  • PHP versions 7.4.x below 7.4.4
  • Debian Linux 10.0
  • Canonical Ubuntu Linux (12.04 ESM, 14.04 ESM, 16.04 LTS, 18.04 LTS, 19.10, 20.04 LTS)
  • Tenable Tenable.sc

Discovery Timeline

  • 2020-04-01 - CVE-2020-7065 published to NVD
  • 2024-11-21 - Last updated in NVD database

Technical Details for CVE-2020-7065

Vulnerability Analysis

This vulnerability exists within PHP's multibyte string extension (mbstring), specifically in the mb_strtolower() function implementation. The root cause is a stack-based buffer overflow (CWE-121) that occurs during the processing of UTF-32LE encoded strings. When certain invalid or malformed UTF-32LE character sequences are passed to the function, PHP fails to properly validate the input boundaries before performing string operations, leading to out-of-bounds write (CWE-787) conditions.

The vulnerability is particularly dangerous because it can be triggered through network-accessible vectors in web applications that process user-supplied string data through PHP's multibyte string functions. An attacker can craft malicious input that, when processed, overwrites adjacent stack memory beyond the allocated buffer boundaries.

Root Cause

The vulnerability stems from improper bounds checking in the mb_strtolower() function when handling UTF-32LE encoded strings. The function allocates a fixed-size stack buffer for string conversion operations but fails to properly validate that the output does not exceed this buffer when processing certain malformed UTF-32LE input sequences. This improper input validation (CWE-787) allows an attacker to write data beyond the allocated buffer, corrupting adjacent stack memory.

Attack Vector

The attack requires network access and user interaction to exploit. An attacker can target web applications that process user-controlled input through the mb_strtolower() function with UTF-32LE encoding. The attack flow typically involves:

  1. Identifying a PHP application that uses mb_strtolower() with user-controllable string input
  2. Crafting a malicious string with specific invalid UTF-32LE byte sequences
  3. Submitting the payload to the target application through web forms, API endpoints, or other input vectors
  4. Triggering the buffer overflow when the application processes the input, potentially leading to code execution

The vulnerability exploits the string encoding conversion process. When PHP attempts to convert a malformed UTF-32LE string to lowercase, the improper handling of certain byte sequences causes a write beyond the stack buffer boundaries. For detailed technical information, refer to the PHP Bug Report #79371.

Detection Methods for CVE-2020-7065

Indicators of Compromise

  • Unexpected PHP crashes or segmentation faults in applications using mbstring functions
  • Anomalous web requests containing unusually large or malformed UTF-32LE encoded payloads
  • Memory corruption errors in PHP error logs related to string processing operations
  • Unusual process behavior or unexpected child processes spawned from PHP workers

Detection Strategies

  • Monitor PHP error logs for segmentation faults and memory corruption errors, particularly those referencing mbstring or mb_strtolower()
  • Implement web application firewall (WAF) rules to detect and block requests with abnormally large or malformed UTF-32LE encoded content
  • Deploy intrusion detection signatures that identify exploitation patterns targeting PHP string encoding functions
  • Audit application code for usage of mb_strtolower() with UTF-32LE encoding and user-controllable input

Monitoring Recommendations

  • Enable PHP error logging at debug level to capture detailed stack traces during crashes
  • Configure application performance monitoring to alert on sudden increases in PHP process crashes
  • Implement file integrity monitoring on PHP binaries and critical application files
  • Monitor network traffic for unusual patterns of requests targeting PHP endpoints with encoded payloads

How to Mitigate CVE-2020-7065

Immediate Actions Required

  • Upgrade PHP to version 7.3.16 or later (for 7.3.x branch) or 7.4.4 or later (for 7.4.x branch)
  • Apply security patches from your Linux distribution vendor (Debian, Ubuntu, etc.)
  • Review application code for usage of mb_strtolower() with UTF-32LE encoding and consider input validation
  • Implement web application firewall rules to filter potentially malicious encoded payloads

Patch Information

PHP has released patched versions that address this vulnerability. Organizations should upgrade to PHP 7.3.16 or 7.4.4 or later versions. Detailed changes can be found in the PHP ChangeLog Version 7.4.4.

For Linux distributions, security updates are available:

  • Debian: DSA-4719 Security Announcement
  • Ubuntu: USN-4330-1 Advisory and USN-4330-2 Advisory
  • Tenable.sc: Tenable Security Notification TNS-2021-14

Workarounds

  • Avoid using mb_strtolower() with UTF-32LE encoding until patches can be applied
  • Implement strict input validation and sanitization for string data before passing to mbstring functions
  • Consider using alternative encoding (such as UTF-8) where UTF-32LE is not strictly required
  • Deploy web application firewalls with rules to detect and block malformed encoded payloads
bash
# Check current PHP version
php -v

# Update PHP on Debian/Ubuntu systems
sudo apt-get update
sudo apt-get upgrade php

# Verify mbstring extension version
php -m | grep mbstring
php -r "echo phpinfo();" | grep -i mbstring

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

  • Vulnerability Details
  • TypeBuffer Overflow

  • Vendor/TechPhp

  • SeverityHIGH

  • CVSS Score8.8

  • EPSS Probability7.27%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityHigh
  • AvailabilityHigh
  • CWE References
  • CWE-121

  • CWE-787
  • Technical References
  • NetApp Security Advisory NTAP-20200403-0001

  • Ubuntu USN-4330-1 Advisory

  • Ubuntu USN-4330-2 Advisory

  • Debian DSA-4719 Security Announcement

  • Tenable Security Notification TNS-2021-14
  • Vendor Resources
  • PHP Bug Report #79371

  • Oracle Critical Patch Update October 2021

  • PHP ChangeLog Version 7.4.4
  • Related CVEs
  • CVE-2024-8932: PHP ldap_escape() Buffer Overflow Flaw

  • CVE-2024-11236: PHP ldap_escape() Buffer Overflow Flaw

  • CVE-2024-11233: PHP Buffer Overflow Vulnerability

  • CVE-2023-3824: PHP PHAR Buffer Overflow Vulnerability
Experience the World’s Most Advanced Cybersecurity Platform

Experience the World’s Most Advanced Cybersecurity Platform

See how our intelligent, autonomous cybersecurity platform can protect your organization now 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