BreachSpiderVerified, not vibes

CVE-2026-40902 in Phpoffice Phpspreadsheet

High 7.5

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

Affects 1 product from 1 vendor. Facts below cite their sources.

CVSS 3.17.5
EPSS0.5%
EPSS percentile35th
FixUnknown

Remotely exploitable over the network, low complexity, no authentication required, no user interaction needed, impact contained to the vulnerable component, no confidentiality impact, no integrity impact, full availability impact.

Affected products and versions

VendorProductAffected versions
Phpoffice Phpspreadsheet < 1.30.4 ≥ 2.0.0, < 2.1.16 ≥ 2.2.0, < 2.4.5 ≥ 3.3.0, < 3.10.5 ≥ 4.0.0, < 5.7.0

A product listed here is affected only at the versions shown. Use the free check to test the exact version you run.

Fix and vendor advisory

No official vendor advisory link on record. See the CVE record.

Vendor PSIRT: [email protected]

Exploitation

CISA known-exploitedNot in the CISA KEV catalog
Public exploitNot confirmed

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

Source: NIST NVD / MITRE CVE.

Record details

CVE IDCVE-2026-40902
BreachSpider IDBS-2026-GLOBAL-152352-H
CVSS vectorCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Published2026-05-12
Last modified2026-10-26
Weakness (CWE)
SourceNVD

Weakness definitions

CWE-770: Allocation of Resources Without Limits or Throttling

Software allocates resources without imposing limits, allowing attackers to exhaust system capacity.

Related attack patterns (CAPEC)

CAPEC-147 XML Ping of the Death via CWE-770

CAPEC-197 Exponential Data Expansion via CWE-770

CAPEC-229 Serialized Data Parameter Blowup via CWE-770

CAPEC-491 Quadratic Data Expansion via CWE-770

CAPEC-230 Serialized Data with Nested Payloads via CWE-770

Show all 20

CAPEC-231 Oversized Serialized Data Payloads via CWE-770

CAPEC-469 HTTP DoS via CWE-770

CAPEC-482 TCP Flood via CWE-770

CAPEC-486 UDP Flood via CWE-770

CAPEC-487 ICMP Flood via CWE-770

CAPEC-488 HTTP Flood via CWE-770

CAPEC-489 SSL Flood via CWE-770

CAPEC-490 Amplification via CWE-770

CAPEC-493 SOAP Array Blowup via CWE-770

CAPEC-494 TCP Fragmentation via CWE-770

CAPEC-495 UDP Fragmentation via CWE-770

CAPEC-496 ICMP Fragmentation via CWE-770

CAPEC-528 XML Flood via CWE-770

CAPEC-125 Flooding via CWE-770

CAPEC-130 Excessive Allocation via CWE-770

Mapping is CWE to CAPEC per MITRE CAPEC 3.9.

Analysis AI-written, not human-reviewed

{ "executive_summary": "PhpSpreadsheet versions prior to 1.30.4, 2.1.16, 2.4.5, 3.10.5, and 5.7.0 are vulnerable to an integer overflow in the XLSX reader's ColumnAndRowAttributes::readRowAttributes() method, allowing an attacker to craft a malicious XLSX file that could lead to a denial of service or potentially arbitrary code execution.", "attack_vector_detail": "An attacker can create a specially crafted XLSX file that contains row numbers exceeding the maximum allowed row limit (1,048,576). When this file is processed by the vulnerable PhpSpreadsheet library, it can cause an integer overflow, leading to undefined behavior such as a denial of service or, in some cases, arbitrary code execution.", "affected_components": ["PhpSpreadsheet 1.30.3 and earlier", "PhpSpreadsheet 2.1.15 and earlier", "PhpSpreadsheet 2.4.4 and earlier", "PhpSpreadsheet 3.10.4 and earlier", "PhpSpreadsheet 5.6.9

Vulnerability details: 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 subsequ CVSS vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H.

Questions

What is CVE-2026-40902?

{ "executive_summary": "PhpSpreadsheet versions prior to 1.30.4, 2.1.16, 2.4.5, 3.10.5, and 5.7.0 are vulnerable to an integer overflow in the XLSX reader's ColumnAndRowAttributes::readRowAttributes() method, allowing an attacker to craft a malicious XLSX file that could lead to a denial of service or potentially arbitrary code execution.", "attack_vector_detail": "An attacker can create a specially crafted XLSX file that contains row numbers exceeding the maximum allowed row limit (1,048,57

What is the CVSS score for CVE-2026-40902?

CVE-2026-40902 has CVSS 7.5 (High). Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H. EPSS: 0.5%.

Is CVE-2026-40902 actively exploited?

No confirmed active exploitation of CVE-2026-40902 as of 2026-11-03.

How do I remediate CVE-2026-40902?

Priority: MEDIUM. PSIRT: [email protected]

What systems are affected by CVE-2026-40902?

CVE-2026-40902 affects Phpoffice Phpspreadsheet.

For developers and AI agents

Run this check from your own code or agent

REST API

curl -s https://breachspider.com/api/v1/assets/correlate-cves \
 -H "Authorization: Bearer $BREACHSPIDER_API_KEY" \
 -H "Content-Type: application/json" \
 -d '{"assets":[{"asset_id":"dev-1","vendor":"Phpoffice","product":"Phpspreadsheet","version":"1.0"}]}'

API reference

Python SDK

pip install breachspider

PyPI · GitHub

MCP for AI agents

# hosted: add as a connector
https://mcp.breachspider.com/mcp
# local
pipx install breachspider-mcp

Setup for Claude, ChatGPT, Cursor

Free trial: 14 days, 750 device checks, no card.

Page facts from NVD, MITRE, CISA and vendor advisories, record last modified 2026-10-26.