# CVE-2026-34084: PHPOffice PhpSpreadsheet RCE and SSRF via PHP Stream Wrappers

Source: https://junglewise.ai/threats/cve-2026-34084-phpoffice-phpspreadsheet-rce-and-ssrf-via-php-stream-wrappers  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2026-05-05. Updated: 2026-07-25  
License: CC BY 4.0 with a link back

CVE-2026-34084 · Severity: critical · CVSS 9.8 · Published 2026-05-05

PhpSpreadsheet is a widely used PHP library for reading and writing spreadsheet files, often integrated into web applications for data imports. A security flaw allows attackers to provide malicious file paths that trick the server into performing unintended actions. This can lead to the theft of internal data or, in some cases, allow an attacker to take full control of the server by executing malicious code.

Technologies: [phpoffice/phpspreadsheet (Packagist)](https://junglewise.ai/threats/technologies/phpoffice-phpspreadsheet), [Phpoffice Phpspreadsheet](https://junglewise.ai/threats/technologies/phpspreadsheet). Vendors: [Packagist](https://junglewise.ai/threats/vendors/packagist), [Phpoffice](https://junglewise.ai/threats/vendors/phpoffice).

## Quick answers

**Is CVE-2026-34084 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2026-34084 being exploited in the wild.

**How severe is CVE-2026-34084?** Critical severity, with a CVSS score of 9.8, published 5 May 2026.

**Which products and versions are affected?** phpoffice/phpspreadsheet (Packagist) ECOSYSTEM:introduced=4.0.0,fixed=5.6.0; Phpoffice Phpspreadsheet <= 1.30.2, 2.0.0 - 2.1.14, 2.2.0 - 2.4.3, 3.3.0 - 3.10.3, 4.0.0 - 5.5.0.

**Is there a fix for CVE-2026-34084?** Yes. phpoffice/phpspreadsheet (Packagist): upgrade to 5.6.0 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is CVE-2026-34084 attacked?** It is attacked over the network, in a software library.

**Am I affected by CVE-2026-34084?** Check whether you run phpoffice/phpspreadsheet (Packagist) or Phpoffice Phpspreadsheet at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## How to fix

- phpoffice/phpspreadsheet (Packagist): upgrade to 5.6.0 or later

  ```sh
  composer require phpoffice/phpspreadsheet:^5.6.0
  ```


## Technical details

A vulnerability exists in the IOFactory::load() method of PhpSpreadsheet due to insufficient validation of the filename argument. The library uses File::assertFile(), which relies on the PHP is_file() function; this function is aware of PHP stream wrappers. An attacker can provide paths using wrappers such as phar://, ftp://, or ssh2.sftp://. The phar:// wrapper triggers deserialization of PHAR metadata, which can lead to Remote Code Execution (RCE) if a suitable POP gadget chain exists in the application environment. Additionally, ftp:// and ssh2.sftp:// wrappers can be used to perform Server-Side Request Forgery (SSRF). The issue is fixed in versions 1.30.3, 2.1.15, 2.4.4, 3.10.4, and 5.6.0.

## Affected products

- PHPOffice PhpSpreadsheet <= 1.30.2, 2.0.0 - 2.1.14, 2.2.0 - 2.4.3, 3.3.0 - 3.10.3, 4.0.0 - 5.5.0

## Identifiers

- CVE-2026-34084
- GHSA-q4q6-r8wh-5cgh

## Timeline

- 2026-04-28: advisory: Original GitHub security advisory published
- 2026-05-05: disclosed: CVE-2026-34084 published to NVD

## References

- [https://github.com/PHPOffice/PhpSpreadsheet/security/advisories/GHSA-q4q6-r8wh-5cgh](https://github.com/PHPOffice/PhpSpreadsheet/security/advisories/GHSA-q4q6-r8wh-5cgh)

## Related threats

- [PHPOffice PhpSpreadsheet redirect validation bypass in external image loading](https://junglewise.ai/threats/cve-2026-108360-phpspreadsheet-is-a-pure-php-library-for-reading-and-writing)
- [PhpSpreadsheet denial-of-service via unbounded row repetition](https://junglewise.ai/threats/cve-2026-108359-phpspreadsheet-is-a-pure-php-library-for-reading-and-writing)
- [PhpSpreadsheet XmlScanner XML entity expansion denial of service](https://junglewise.ai/threats/cve-2026-108358-phpspreadsheet-is-a-pure-php-library-for-reading-and-writing)
- [PHPOffice PhpSpreadsheet XML entity expansion denial of service](https://junglewise.ai/threats/cve-2026-108357-phpspreadsheet-is-a-pure-php-library-for-reading-and-writing)
- [MediaWiki DataTransfer Extension uncontrolled resource consumption](https://junglewise.ai/threats/cve-2026-100242-dependency-on-vulnerable-third-party-component-and-uncontrolled)
