SourceCodester Pharmacy Sales and Inventory System
cpe:2.3:a:pharmacy_sales_and_inventory_system_project:pharmacy_sales_and_inventory_system:*:*:*:*:*:*:*
- 1.0
A cross-site scripting (XSS) vulnerability has been identified in SourceCodester Pharmacy Sales and Inventory System version 1.0. The issue resides in the file '/index.php?page=categories', where the 'id' parameter is not properly validated or encoded before being output to users. This flaw allows attackers to inject and execute malicious scripts in the context of the user's browser, potentially leading to the theft of cookies, session tokens, or other sensitive information.
Exploitation of this vulnerability allows for cross-site scripting, where injected scripts are executed in the context of the user's browser.
To reproduce this vulnerability, navigate to the '/index.php?page=categories' endpoint and manipulate the 'id' parameter by injecting a script payload, such as a script tag containing JavaScript code. The injected script will be executed in the browser, demonstrating the cross-site scripting vulnerability.
It is recommended to implement proper output encoding for user inputs, validate and filter input data to reject malicious content, and consider using a Content Security Policy to restrict script sources. Regular security audits can also help identify and address such vulnerabilities.
Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.