Stored Cross-Site Scripting (XSS) in snipe/snipe-it
Reported on
Aug 28th 2022
Description
Input fields allowing Markdown Input are vulnerable to XSS. This requires Superadmin permissions though.
Proof of Concept
Steps to reproduce:
1. Log in to the admin account
2. Go to Admin -> General Settings
3. Enter the Payload in the `Login Note` and `Dashboard Message` fields.
4. Go to the Dashboard & confirm the XSS in the dasboard message. Logout and confirm the XSS in the login message.
Payload:
[XSS](javascript:alert(document.location))
Impact
The impact is JavaScript Code Execution. However, superadmin privileges are required to edit the vulnerable input fields.
Occurrences
dashboard.blade.php L20
According to the Parsedown Readme, to prevent XSS it is required to set the safemode: $Parsedown->setSafeMode(true);
login.blade.php L31
According to the Parsedown Readme, to prevent XSS it is required to set the safemode: $Parsedown->setSafeMode(true);