{"id":"CVE-2025-22131","published":"2025-01-20T15:31:19Z","modified":"2025-01-21T14:58:15Z","title":"Cross-Site Scripting (XSS) vulnerability in generateNavigation() function","vendor":"PHPOffice","product":"PhpSpreadsheet","tier":"tail","description":{"text":"PhpSpreadsheet is a PHP library for reading and writing spreadsheet files. Cross-Site Scripting (XSS) vulnerability in the code which translates the XLSX file into a HTML representation and displays it in the response.","provenance":"source","from":"CVE.org"},"cvss":{"score":5.1,"severity":"MEDIUM","version":"4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:A/VC:L/VI:L/VA:N/SC:L/SI:L/SA:N","provenance":"source","from":"CVE.org CNA"},"epss":{"score":0.00396,"percentile":0.34669,"provenance":"source"},"cwes":[{"id":"CWE-79","name":"Improper Neutralization of Input During Web Page Generation"}],"references":[{"url":"https://github.com/PHPOffice/PhpSpreadsheet/security/advisories/GHSA-79xx-vf93-p7cx","tags":["x_refsource_CONFIRM"]},{"url":"https://github.com/PHPOffice/PhpSpreadsheet/commit/4088381ccfaf241d7d42c333de0dc8c98e338743","tags":["x_refsource_MISC"]}],"priority":{"score":15.5,"factors":[{"name":"EPSS percentile","points":6.93},{"name":"Public exploit code","points":5.0},{"name":"CVSS severity","points":3.57}]},"exploitSources":{"pocGithub":{"count":2,"skipped":0,"earliest":"2025-09-03","earliestUrl":"https://github.com/ZzN1NJ4/CVE-2025-22131-PoC","repos":[{"name":"s0ck37/CVE-2025-22131-POC","url":"https://github.com/s0ck37/CVE-2025-22131-POC","stars":3,"created":"2025-09-05"},{"name":"ZzN1NJ4/CVE-2025-22131-PoC","url":"https://github.com/ZzN1NJ4/CVE-2025-22131-PoC","stars":1,"created":"2025-09-03"}]},"first":{"date":"2025-09-03","source":"PoC-in-GitHub","url":"https://github.com/ZzN1NJ4/CVE-2025-22131-PoC"},"provenance":"source"},"vendorSlug":"phpoffice","affectedVersions":[{"vendor":"PHPOffice","product":"PhpSpreadsheet","versions":[">= 3.0.0, < 3.8.0",">= 2.2.0, < 2.3.6",">= 2.0.0, < 2.1.7","< 1.29.8"]}],"ssvc":{"exploitation":"poc","automatable":"no","technicalImpact":"partial","timestamp":"2025-01-21T14:58:10.245886Z","from":"CISA ADP","provenance":"source"},"affected":[{"ecosystem":"Packagist","package":"phpoffice/phpspreadsheet","vulnerableRanges":[">=3.0.0, <3.8.0","<1.29.8",">=2.0.0, <2.1.7",">=2.2.0, <2.3.6"],"patched":["3.8.0","1.29.8","2.1.7","2.3.6"],"from":["GHSA-79xx-vf93-p7cx"],"provenance":"source"},{"ecosystem":"Packagist","package":"phpoffice/phpexcel","vulnerableRanges":["<=1.8.2"],"patched":[],"from":["GHSA-79xx-vf93-p7cx"],"provenance":"source"}],"summary":{"text":"A cross-site scripting flaw in PhpSpreadsheet, a PHP library for reading and writing spreadsheet files, lies in the code that converts XLSX files into an HTML representation for display in responses. An attacker can get script injected into that output by supplying a crafted XLSX file, and the attack needs only network access and no authentication, but it requires a user to interact with the rendered content (for example, by opening the converted page).","provenance":"ai","model":"claude-haiku-5-5","generatedAt":"2026-11-20T22:03:08Z"},"euvd":{"id":"EUVD-2025-0143","exploited":false,"provenance":"source"},"lineage":{"packageHistory":[{"cve":"CVE-2024-56410","published":"2025-01-03","fixed":"3.7.0","kev":false},{"cve":"CVE-2024-56411","published":"2025-01-03","fixed":"3.7.0","kev":false},{"cve":"CVE-2024-56412","published":"2025-01-03","fixed":"3.7.0","kev":false},{"cve":"CVE-2025-22131","published":"2025-01-20","fixed":"3.8.0","kev":false},{"cve":"CVE-2025-23210","published":"2025-02-03","fixed":"3.9.0","kev":false,"link":{"from":"CVE-2025-22131","to":"CVE-2025-23210","relation":"successor","confidence":"high","kind":"sequence","evidence":[{"kind":"version-step","provenance":"source","package":"Packagist:phpoffice/phpspreadsheet","fromFixed":"3.8.0","toFixed":"3.9.0","daysApart":14},{"kind":"version-step","provenance":"source","package":"Packagist:phpoffice/phpspreadsheet","fromFixed":"2.3.6","toFixed":"2.3.7","daysApart":14},{"kind":"same-code","provenance":"machine","files":["src/PhpSpreadsheet/Writer/Html.php"],"commits":["https://github.com/PHPOffice/PhpSpreadsheet/commit/4088381ccfaf241d7d42c333de0dc8c98e338743","https://github.com/PHPOffice/PhpSpreadsheet/commit/cde2926a9e2baf146783f8fd1771bbed7d1dc7b3"],"basis":"shared file"}]}},{"cve":"CVE-2025-54370","published":"2025-08-25","fixed":"5.0.0","kev":false},{"cve":"CVE-2026-34084","published":"2026-05-05","fixed":"5.6.0","kev":false}],"package":"Packagist:phpoffice/phpspreadsheet"}}