PhpSpreadsheet: SSRF whitelist bypass via unre-validated HTTP redirect in Drawing::setPath external image loading
CVE-2026-108360GHSA-2phh-27fw-q4gc
What to do
Vendor fix available. Upgrade each affected package to the fixed version on its release line (phpoffice/phpspreadsheet 5.10.0, 3.10.8, 2.4.8, 2.1.19, 1.30.7), redeploy, then verify what is actually installed.
This page has no inventory attached, so it cannot say whether you are affected. A vendor fix is not proof that your deployment is fixed.
Affected packages
Packagist phpoffice/phpspreadsheet
- Affected
- >= 4.0.0, < 5.10.0>= 3.3.0, < 3.10.8>= 2.2.0, < 2.4.8>= 2.0.0, < 2.1.19< 1.30.7
- Fixed in
- 3.10.8, 2.4.8, 2.1.19, 1.30.7, 5.10.0
Sources
- GitHub Advisory Database and maintainer security advisories on GitHub
GitHub-reviewed advisory GHSA-2phh-27fw-q4gc lists affected ranges: Packagist phpoffice/phpspreadsheet >=4.0.0 =3.3.0 =2.2.0 =2.0.0 =0 <=1.30.6
VerifiedObserved Structured GitHub Advisory Database record (type=reviewed) from the GitHub REST API.
- Open Source Vulnerabilities (OSV.dev), including the GitHub Advisory Database
OSV record GHSA-2phh-27fw-q4gc lists affected ranges: Packagist phpoffice/phpspreadsheet >=4.0.0 =3.3.0 =2.2.0 =2.0.0 =0 <1.30.7 (fixed)
VerifiedObserved Structured OSV record; GitHub-reviewed advisory.
Severity and exploitation
- Exploitation
- No confirmed exploitation recorded. Patch Next marks exploitation only from CISA KEV.
- CVSS
- 6.4 · CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:L/A:N
- EPSS
- CVE-2026-108360: 0.34% estimated exploitation activity in the next 30 days; percentile 27.38 (FIRST EPSS, 2026-11-03). This is a model estimate, not proof of exploitation or customer exposure.
Source description
As published by the source; long descriptions are shortened.
Summary PhpSpreadsheet's `Worksheet\Drawing::setPath()` validates an external-image URL against an operator-supplied `isWhitelisted` callback once, on the initial URL only, then fetches it with `file_get_contents()` using a stream context that does not set `follow_location => 0`. A whitelisted host that returns an HTTP `302 Location:` redirect to an internal target is therefore followed by PHP's HTTP wrapper (default `follow_location=1`, `max_redirects=20`) with no re-validation of the redirect hop — defeating the whitelist and yielding a blind SSRF from the server. This is an unfixed variant of CVE-2026-59931 (GHSA-6hq5-7373-42rg, the WEBSERVICE redirect-whitelist-bypass): the `follow_location => 0` fix (commit `7ef7b25e`) was applied ONLY to `Calculation/Web/Service.php`; `Worksheet/Drawing.php` was never touched.
Root Cause `src/PhpSpreadsheet/Worksheet/Drawing.php`: - Scheme allowlist at `:125` (`/^(http|https|file|ftp|s3):/`) permits `http`/`https` (the…
Dates and revisions
- Published by the source
- Last modified by the source
- Source last checked
- Revision 2 · amended ·
Amended from osv record GHSA-2phh-27fw-q4gc
- Revision 1 · created ·
Published from ghsa record GHSA-2phh-27fw-q4gc
Agent brief
Preview the exact text before you copy it. Commands are read-only suggestions; review them before running anything.
# Patch Next advisory brief: CVE-2026-108360 Advisory: PhpSpreadsheet: SSRF whitelist bypass via unre-validated HTTP redirect in Drawing::setPath external image loading IDs: CVE-2026-108360, GHSA-2phh-27fw-q4gc Record: https://patchnext.com/advisories/cve-2026-108360 (revision 2, source checked 28 Oct 2026, 06:30 UTC) Inventory: none attached. This brief comes from a public page and does not say whether any deployment is affected. Severity: Medium (CVSS 6.4) Exploitation: no confirmed exploitation recorded. Patch Next confirms exploitation only from CISA KEV. Vendor response: Vendor fix available; fixed versions by package: phpoffice/phpspreadsheet 5.10.0, 3.10.8, 2.4.8, 2.1.19, 1.30.7. A vendor fix does not mean a deployment is fixed. ## Affected components - Packagist phpoffice/phpspreadsheet: affected >= 4.0.0, < 5.10.0; >= 3.3.0, < 3.10.8; >= 2.2.0, < 2.4.8; >= 2.0.0, < 2.1.19; < 1.30.7; fixed in 3.10.8, 2.4.8, 2.1.19, 1.30.7, 5.10.0 ## Suggested inspection (read-only) - Packagist phpoffice/phpspreadsheet: check the installed version with your package manager. ## Supported action Upgrade each affected component to a fixed version on its release line. For a transitive dependency, upgrade the parent package or add an override or constraint, then regenerate the lockfile. Redeploy every environment that ran an affected version. ## Required regression checks - Run the test suite and a production build. - Exercise the features that depend on phpoffice/phpspreadsheet. - Repeat the inspection and confirm that only fixed versions remain installed. ## Rollback considerations - Keep the previous lockfile and deployment artifact. Rolling back reinstates the vulnerable version, so apply any documented mitigation while you fix forward. ## Unresolved questions - Which deployments run an affected version? - Exploitation status can change. Check again before lowering the priority. - Mark the work resolved only after the fixed version is verified in production. ## Sources - Verified: https://github.com/advisories/GHSA-2phh-27fw-q4gc (GitHub-reviewed advisory GHSA-2phh-27fw-q4gc lists affected ranges: Packagist phpoffice/phpspreadsheet >=4.0.0 =3.3.0 =2.2.0 =2.0.0 =0 <=1.30.6) - Verified: https://osv.dev/vulnerability/GHSA-2phh-27fw-q4gc (OSV record GHSA-2phh-27fw-q4gc lists affected ranges: Packagist phpoffice/phpspreadsheet >=4.0.0 =3.3.0 =2.2.0 =2.0.0 =0 <1.30.7 (fixed)) Commands are suggestions: review each one before running it.
Loading voting…