Advisory Database
  • Advisories
  • Dependency Scanning
  1. composer
  2. ›
  3. phpoffice/phpspreadsheet
  4. ›
  5. CVE-2025-23210

CVE-2025-23210: PhpSpreadsheet allows bypassing of XSS sanitizer using the javascript protocol and special characters

February 3, 2025 (updated March 6, 2025)

Product: PhpSpreadsheet Version: 3.8.0 CWE-ID: CWE-79: Improper Neutralization of Input During Web Page Generation (‘Cross-site Scripting’) CVSS vector v.3.1: 5.4 (AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N) CVSS vector v.4.0: 4.8 (AV:N/AC:L/AT:N/PR:L/UI:A/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N) Description: an attacker can use special characters, so that the library processes the javascript protocol with special characters and generates an HTML link Impact: executing arbitrary JavaScript code in the browser Vulnerable component: class PhpOffice\PhpSpreadsheet\Writer\Html, method generateRow Exploitation conditions: a user viewing a specially generated xml file Mitigation: additional sanitization of special characters in a string Researcher: Igor Sak-Sakovskiy (Positive Technologies)

References

  • github.com/PHPOffice/PhpSpreadsheet
  • github.com/PHPOffice/PhpSpreadsheet/commit/cde2926a9e2baf146783f8fd1771bbed7d1dc7b3
  • github.com/PHPOffice/PhpSpreadsheet/security/advisories/GHSA-r57h-547h-w24f
  • github.com/advisories/GHSA-r57h-547h-w24f
  • nvd.nist.gov/vuln/detail/CVE-2025-23210

Code Behaviors & Features

Detect and mitigate CVE-2025-23210 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 1.29.9, all versions starting from 2.0.0 before 2.1.8, all versions starting from 2.2.0 before 2.3.7, all versions starting from 3.0.0 before 3.9.0

Fixed versions

  • 3.9.0
  • 1.29.9
  • 2.3.7
  • 2.1.8

Solution

Upgrade to versions 1.29.9, 2.1.8, 2.3.7, 3.9.0 or above.

Impact 5.4 MEDIUM

CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N

Learn more about CVSS

Weakness

  • CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')

Source file

packagist/phpoffice/phpspreadsheet/CVE-2025-23210.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Wed, 14 May 2025 12:14:26 +0000.