CVE-2026-40902

PhpSpreadsheet: CPU Denial of Service via Unbounded Row Number in XLSX Row Dimensions

HIGH
7.5
CVSS Score
Published: May 12, 2026 at 10:02 PM UTC
Updated: June 17, 2026 at 10:45 AM UTC
1 product affected across 1 vendorPhpSpreadsheet

Using PhpSpreadsheet by PHPOffice?

Get instant alerts when new vulnerabilities affect PhpSpreadsheet - before attackers find them.

Real-time alertsTrack your software stackFree plan available
Severity
HIGH7.5
Exploit prediction
EPSS 0.4%
SSVC
PoC

Description

PhpSpreadsheet is a pure PHP library for reading and writing spreadsheet files. Prior to 1.30.4, 2.1.16, 2.4.5, 3.10.5, and 5.7.0, the XLSX reader's ColumnAndRowAttributes::readRowAttributes() method reads row numbers from XML attributes without validating them against the spreadsheet maximum row limit (AddressRange::MAX_ROW = 1,048,576). An attacker can craft a minimal XLSX file (~1.6KB) containing a <row r="999999999"/> element that inflates cachedHighestRow to 999,999,999, causing any subsequent row iteration to attempt ~1 billion loop cycles and exhaust CPU resources. This vulnerability is fixed in 1.30.4, 2.1.16, 2.4.5, 3.10.5, and 5.7.0.

Affected

Our own answer: ranges merged, affected separated from platform-only, with confidence and review flags.

v < 1.30.4v < 2.1.16v < 2.4.5v < 3.10.5v < 5.7.02.0.0 ≤ v < 2.1.162.2.0 ≤ v < 2.4.53.3.0 ≤ v < 3.10.54.0.0 ≤ v < 5.7.0
Affected range stops below 1.30.4, so it looks safe — our inference, not a vendor statement
Affected range stops below 2.1.16, so it looks safe — our inference, not a vendor statement
Affected range stops below 2.4.5, so it looks safe — our inference, not a vendor statement
Affected range stops below 3.10.5, so it looks safe — our inference, not a vendor statement
Affected range stops below 5.7.0, so it looks safe — our inference, not a vendor statement

Remediation

No guide yet

No remediation guidance has been written for this CVE yet. What the record does show:

References (1)

x_refsource_CONFIRMExploitMitigationVendor Advisory
Source: cverecord
https://github.com/PHPOffice/PhpSpreadsheet/security/advisories/GHSA-7c6m-4442-2x6m

SSVC — Action Prioritization

SSVCPoCAutomatablePartial impact

SSVC signals action urgency (what to patch first), separate from CVSS which measures severity.

CVSS

7.5HIGHGitHub_M
Attack Vector
NETWORK
Complexity
LOW
Privileges
NONE
User Interaction
NONE
Scope
UNCHANGED
Confidentiality
NONE
Integrity
NONE
Availability
HIGH
Vector?

Quick Info

StatusANALYZED
CWE
CWE-770

Get alerted

Stop reading CVE feeds looking for your own stack

Track the products you run and VulnTracker tells you when a new CVE affects them — with what is known about fixing it, and nothing about the rest.

Free plan, no card