CVE-2024-56412
published 2025-01-03CVE-2024-56412: PhpSpreadsheet is a PHP library for reading and writing spreadsheet files. Versions prior to 3.7.0, 2.3.5, 2.1.6, and 1.29.7 are vulnerable to bypass of the…
PriorityP425medium5.4CVSS 3.1
AVNACLPRLUIRSCCLILAN
EPSS
0.37%
28.5th percentile
PhpSpreadsheet is a PHP library for reading and writing spreadsheet files. Versions prior to 3.7.0, 2.3.5, 2.1.6, and 1.29.7 are vulnerable to bypass of the cross-site scripting sanitizer using the javascript protocol and special characters. An attacker can use special characters, so that the library processes the javascript protocol with special characters and generates an HTML link. Versions 3.7.0, 2.3.5, 2.1.6, and 1.29.7 contain a patch for the issue.
Affected
12 ranges
| Vendor | Product | Version range | Fixed in |
|---|---|---|---|
| phpoffice | phpexcel | 0 – 1.8.2 | — |
| phpoffice | phpspreadsheet | < 1.29.7 | 1.29.7 |
| phpoffice | phpspreadsheet | — | — |
| phpoffice | phpspreadsheet | — | — |
| phpoffice | phpspreadsheet | — | — |
| phpoffice | phpspreadsheet | >= 0 < 1.29.7 | 1.29.7 |
| phpoffice | phpspreadsheet | >= 2.0.0 < 2.1.6 | 2.1.6 |
| phpoffice | phpspreadsheet | >= 2.0.0 < 2.1.6 | 2.1.6 |
| phpoffice | phpspreadsheet | >= 2.2.0 < 2.3.5 | 2.3.5 |
| phpoffice | phpspreadsheet | >= 2.2.0 < 2.3.5 | 2.3.5 |
| phpoffice | phpspreadsheet | >= 3.0.0 < 3.7.0 | 3.7.0 |
| phpoffice | phpspreadsheet | >= 3.0.0 < 3.7.0 | 3.7.0 |
CVSS provenance
nvdv3.15.4MEDIUMCVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:L/I:L/A:N
nvdv4.04.8MEDIUMCVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:A/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
Stop checking back — get the weekly exploitation signal.
Every Monday: what got weaponized or added to CISA KEV in the last seven days — each CVE cross-linked to its PoC, Nuclei template, and detection rule. Free, one email a week, unsubscribe in one click.
GHSA
PhpSpreadsheet allows bypass XSS sanitizer using the javascript protocol and special characters
ghsa·2025-01-03
CVE-2024-56412 [MEDIUM] CWE-79 PhpSpreadsheet allows bypass XSS sanitizer using the javascript protocol and special characters
PhpSpreadsheet allows bypass XSS sanitizer using the javascript protocol and special characters
# Bypass XSS sanitizer using the javascript protocol and special characters
**Product**: Phpspreadsheet
**Version**: version 3.6.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`
OSV
PhpSpreadsheet allows bypass XSS sanitizer using the javascript protocol and special characters
osv·2025-01-03
CVE-2024-56412 [MEDIUM] PhpSpreadsheet allows bypass XSS sanitizer using the javascript protocol and special characters
PhpSpreadsheet allows bypass XSS sanitizer using the javascript protocol and special characters
# Bypass XSS sanitizer using the javascript protocol and special characters
**Product**: Phpspreadsheet
**Version**: version 3.6.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`
No detection rules found.
No public exploits indexed.
No writeups or analysis indexed.
2025-01-03
Published