PoC Monitor
← All CVEs
CVE-2026-45034published 22 Jun 2026 20:32 UTCData: JSON · API

PHPOffice PhpSpreadsheet

PhpSpreadsheet: File::prohibitWrappers bypass

PhpSpreadsheet is a pure PHP library for reading and writing spreadsheet files. Prior to 1.30.5, CVE-2026-34084 was patched by the helper File::prohibitWrappers. The helper calls parse_url($filename, PHP_URL_SCHEME) and then checks is_string($scheme) && strlen($scheme) > 1 to reject stream wrappers such as phar://, php://, data:// or expect://. The check is not equivalent to "does the path contain a wrapper". When the input has the form phar:///path/file.phar/inner with three or more slashes after the scheme, parse_url returns boolean false instead of returning the scheme string. The is_string($scheme) branch is therefore skipped, the helper returns without throwing, and the caller proceeds. PHP's stream layer, however, still treats phar:///... as a valid phar wrapper and opens the underlying phar file. The result is that IOFactory::load($attackerPath) walks past the patch and still touches the phar wrapper. On PHP 7.x, simply reaching the phar wrapper via is_file is enough for PHP to automatically deserialize the phar metadata, which in turn invokes the magic methods __wakeup and __destruct of an attacker controlled object and gives full RCE. On PHP 8.x, automatic metadata deserialization for plain file ops was removed, so the chain at the PhpSpreadsheet layer reduces to a phar wrapper file read primitive, and RCE only resurfaces if the downstream consumer ever calls Phar::getMetadata. This vulnerability is fixed in 1.30.5.

First public PoC 12 days beforebefore publication · 11 Jun 2026
Public PoCs11 on GitHub
CVSS9.2critical · scored by CNA · CWE-502
CISA KEV Not listednot known exploited

Affected versions and mitigation

From the CVE record and the vendor's references.

Affected

PHPOffice PhpSpreadsheet
  • < 1.30.5

Fixed in 1.30.5

Mitigation

Upgrade PhpSpreadsheet to 1.30.5 or later.

References

Timeline

Days relative to CVE publication
-12-9-6-3t=0+3+6First public PoC11 Jun 2026 · t−12dCVE published22 Jun 2026 · t = 0

First public PoC 12 days before publication; not in CISA KEV. First PoC: SangSenimanWartefak/CVE-2026-45034 (created 11 Jun 2026, found by us: backfilled).

PoC repositories

Found on GitHub.

1 PoCs

PoCs 1
RepositoryCreatedStarsAssessment
SangSenimanWartefak/CVE-2026-45034 11 Jun 2026 −12 d 0 PoC

Only PoCs count toward the first-PoC date and the characteristics below. Do not run PoC code from unknown sources.

PoC characteristics

What to hunt for in your logs · from 1 PoC repo

POST /vendor/phpoffice/phpspreadsheet/samples/index.php

Body markers
------WebKitFormBoundary Content-Disposition: form-data; name="file"; filename=" in multipart/form-data; boundary=----WebKitFormBoundary
Seen in
1 repo: SangSenimanWartefak/CVE-2026-45034
Evidence
SangSenimanWartefak/CVE-2026-45034/CVE-2026-45034.yaml:21

Regex

Generated from PoC characteristics; not yet reviewed. Matches the request path and query.

POST /vendor/phpoffice/phpspreadsheet/samples/index.php
(?i)^/vendor/phpoffice/phpspreadsheet/samples/index\.php(?:[?#].*)?$

Suricata

Template generated from PoC characteristics. Review before deploying.

POST /vendor/phpoffice/phpspreadsheet/samples/index.php
alert http any any -> $HOME_NET any (msg:"GG PoC-Monitor CVE-2026-45034 PHPOffice PhpSpreadsheet exploit attempt"; flow:established,to_server; http.method; content:"POST"; http.uri; content:"/vendor/phpoffice/phpspreadsheet/samples/index.php"; http.request_body; content:"------WebKitFormBoundary
Content-Disposition: form-data|3b| name=|22|file|22||3b| filename=|22|"; reference:url,poc.griffinguard.io/cve/CVE-2026-45034; classtype:web-application-attack; sid:9377703; rev:1;)

Sigma

Template generated from PoC characteristics. Review before deploying.

POST /vendor/phpoffice/phpspreadsheet/samples/index.php
title: PHPOffice PhpSpreadsheet exploit attempt (CVE-2026-45034)
id: gg-pocmon-cve-2026-45034-9377703
status: experimental
description: Request pattern taken from public PoCs for CVE-2026-45034. Generated, not reviewed.
references:
  - https://poc.griffinguard.io/cve/CVE-2026-45034
logsource:
  category: webserver
detection:
  selection:
    cs-method: POST
    cs-uri-stem|contains|all:
      - '/vendor/phpoffice/phpspreadsheet/samples/index.php'
  condition: selection
falsepositives:
  - Authorized vulnerability scanning
level: critical
tags:
  - attack.initial_access
  - attack.t1190
  - cve.2026.45034