Multiple Stored XSS Found in fobybus/social-media-skeleton
Reported on
Aug 5th 2023
Description
Stored XSS (Cross-Site Scripting) is a type of web security vulnerability caused by improper input validation and inadequate data sanitization in a web application. It occurs when an attacker injects malicious scripts (usually in the form of HTML or JavaScript) into a website's database or storage, which is then fetched and displayed to unsuspecting users. These scripts are executed in the browsers of those who visit the infected page, enabling the attacker to steal sensitive information, such as login credentials or personal data, and potentially take control of the user's account or perform malicious actions on their behalf. To prevent stored XSS, developers must implement proper input validation and output encoding to ensure that user-supplied data is treated as plain text and not executed as code on the web page.
Proof of Concept
- Register New User
- Enter the following XSS Payload for First Name, Last Name, and City input fields:
// PoC.js
<script>alert(1)</script>
- Login with user
- Once logged in you will see alert boxes for First Name and Last Name
- Navigate to Profile Page, you will see alert boxes for First Name, Last Name, and City
ScreenShots
Impact
An attacker can inject JavaScript on a victims browser that could lead to stealing cookies in addition to installing JavaScript malware, keyloggers and performing remote actions.
@fobybus @maintainer Thanks for validating ! When you have a chance please review the fix / patch I attached, let me know if / when to put in the pull request. Additionally, once the fix has been applied, if you could assign a CVE I would greatly appreciate it. Thank you kindly!
@fobybus @maintainer Just wanted to know why no CVE ? Or will you wait till after it goes public to assign a CVE ?
@admin There was CVE applied to this issue (registered through Github). Would it be possible to add it to this report ? https://nvd.nist.gov/vuln/detail/CVE-2023-39518