CVE-2026-30571
Reflected XSS in SourceCodester Inventory System view_category.php
Publication date: 2026-03-27
Last updated on: 2026-04-06
Assigner: MITRE
Description
Description
CVSS Scores
EPSS Scores
| Probability: | |
| Percentile: |
Meta Information
Affected Vendors & Products
| Vendor | Product | Version / Range |
|---|---|---|
| ahsanriaz26gmailcom | inventory_system | 1.0 |
Helpful Resources
Exploitability
| CWE ID | Description |
|---|---|
| CWE-79 | The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users. |
Attack-Flow Graph
AI Powered Q&A
Can you explain this vulnerability to me?
CVE-2026-30571 is a Reflected Cross-Site Scripting (XSS) vulnerability found in SourceCodester Inventory System version 1.0, specifically in the view_category.php file.
The vulnerability occurs because the application accepts a GET parameter named "limit" which controls pagination, but it does not properly sanitize or encode this input.
This allows remote attackers to inject arbitrary JavaScript code via a crafted URL that includes malicious script in the "limit" parameter.
Exploitation requires the attacker to be authenticated, as the vulnerable page is accessible only to logged-in users.
When a logged-in administrator visits the malicious URL, the injected script executes in their browser, confirming the vulnerability.
How can this vulnerability impact me? :
This vulnerability can have serious impacts including session hijacking and privilege escalation.
An attacker can steal administrator session cookies by injecting malicious scripts, allowing them to impersonate the administrator.
With stolen admin privileges, the attacker can perform unauthorized actions within the Inventory System.
How can this vulnerability be detected on my network or system? Can you suggest some commands?
This vulnerability can be detected by verifying if the "limit" parameter in the view_category.php page reflects unsanitized input back to the user. Specifically, an authenticated user (such as an administrator) can test by accessing a crafted URL containing a JavaScript payload in the "limit" parameter.
- Log in as an administrator to the SourceCodester Inventory System.
- Access a URL similar to: http://127.0.0.1:8089/view_category.php?limit=\"><script>alert(15623);</script>
- If an alert box with the number "15623" appears, the vulnerability is present.
This method confirms the reflected XSS vulnerability by demonstrating that arbitrary JavaScript can be executed via the "limit" parameter.
How does this vulnerability affect compliance with common standards and regulations (like GDPR, HIPAA)?:
The Reflected Cross-Site Scripting (XSS) vulnerability in SourceCodester Inventory System 1.0 can lead to session hijacking and privilege escalation by allowing attackers to execute arbitrary scripts in the context of an authenticated administrator.
Such exploitation risks unauthorized access to sensitive data and administrative functions, which may result in violations of data protection regulations like GDPR and HIPAA that require safeguarding personal and sensitive information against unauthorized access and breaches.
Therefore, this vulnerability could negatively impact compliance with these standards by exposing protected data and administrative controls to attackers.
What immediate steps should I take to mitigate this vulnerability?
The vulnerability allows remote attackers to inject arbitrary JavaScript code via the "limit" parameter in the view_category.php file, which is accessible only to authenticated users.
Immediate mitigation steps include:
- Restrict access to the vulnerable page (view_category.php) to trusted users only, minimizing exposure.
- Avoid clicking on or visiting suspicious or untrusted URLs containing the "limit" parameter.
- Implement input validation and sanitization on the "limit" parameter to prevent script injection.
- If possible, apply web application firewall (WAF) rules to detect and block malicious payloads targeting the "limit" parameter.
- Consider logging out and re-authenticating if you suspect your session may have been compromised.