Cross-Site Scripting (XSS) vulnerability in generateNavigation() function in PhpSpreadsheet
SummaryThe researcher discovered zero-day vulnerability Cross-Site Scripting (XSS) vulnerability in the code which translates the XLSX file into a HTML representation and displays it in the response.DetailsWhen generating the HTML from an xlsx file containing multiple sheets, a navigation menu is created. This menu includes the sheet names, which are not sanitized. As a result, an attacker can exploit this vulnerability to execute JavaScript code.PoCCreate an XLSX file with multiple sheets : 
![image](https://github.com/user-attachments/assets/e3fc027a-9525-4d7f-b107-cfa6e78d04e7)Generate the HTML contentEnjoy
![image](https://github.com/user-attachments/assets/3e3c24f4-cb5d-451d-978f-9d33234f3bd1)ImpactXSS can cause a variety of problems for the end user that range in severity from an annoyance to complete account compromise.
Example of impacts :Disclosure of the user’s session cookie, allowing an attacker to hijack the user’s session and take over the account (Only if HttpOnly cookie's flag is set to false).Redirecting the user to some other page or site (like phishing websites)Modifying the content of the current page (add a fake login page that sends credentials to the attacker).Automatically download malicious files.Requests access to the victim geolocation / camera....