CVE-2026-7269
Received Received - Intake
Cross-Site Scripting in SourceCodester Pharmacy Product Page

Publication date: 2026-04-28

Last updated on: 2026-04-29

Assigner: VulDB

Description
A vulnerability was found in SourceCodester Pharmacy Sales and Inventory System 1.0. Affected is an unknown function of the file /index.php?page=product. Performing a manipulation of the argument ID results in cross site scripting. It is possible to initiate the attack remotely. The exploit has been made public and could be used.
CVSS Scores
EPSS Scores
Probability:
Percentile:
Meta Information
Published
2026-04-28
Last Modified
2026-04-29
Generated
2026-05-06
AI Q&A
2026-04-28
EPSS Evaluated
2026-05-05
NVD
EUVD
Affected Vendors & Products
Showing 1 associated CPE
Vendor Product Version / Range
sourcecodester pharmacy_sales_and_inventory_system 1.0
Helpful Resources
Exploitability
CWE
CWE Icon
KEV
KEV Icon
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.
CWE-94 The product constructs all or part of a code segment using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the syntax or behavior of the intended code segment.
Attack-Flow Graph
AI Powered Q&A
How does this vulnerability affect compliance with common standards and regulations (like GDPR, HIPAA)?:

The Cross-Site Scripting (XSS) vulnerability in the Pharmacy Sales and Inventory System allows attackers to execute arbitrary JavaScript code, potentially stealing cookies, session tokens, and other sensitive information. This unauthorized access and data exposure can lead to violations of data protection regulations such as GDPR and HIPAA, which mandate the protection of personal and sensitive information.

Failure to properly secure user inputs and prevent such attacks may result in non-compliance with these standards, as they require organizations to implement adequate security controls to protect user data from unauthorized access and breaches.

Therefore, this vulnerability poses a risk to compliance by exposing sensitive data and undermining the confidentiality and integrity requirements set forth by common regulations.


Can you explain this vulnerability to me?

CVE-2026-7269 is a Cross-Site Scripting (XSS) vulnerability found in the Pharmacy Sales and Inventory System 1.0, specifically in the '/index.php?page=product' file. The vulnerability occurs because the application directly outputs user-supplied input from the 'id' parameter without proper encoding or filtering. This allows attackers to inject and execute arbitrary JavaScript code in the victim's browser.

An attacker can exploit this vulnerability remotely by manipulating the 'id' argument in the URL to inject malicious scripts, such as the proof-of-concept payload `<script>prompt(/xss/);</script>`. This lack of input validation and output encoding makes the system vulnerable to script injection attacks.


How can this vulnerability impact me? :

This XSS vulnerability can have severe impacts including allowing attackers to steal cookies, session tokens, or other sensitive information from users.

  • Attackers can perform unauthorized actions on behalf of the victim.
  • They can deface web pages or redirect users to malicious sites.
  • It may lead to attackers gaining control over the victim's browser.

Exploitation does not require user authentication or authorization, increasing the risk and ease of attack.


How can this vulnerability be detected on my network or system? Can you suggest some commands?

This vulnerability can be detected by testing the 'id' parameter in the URL of the affected page for cross-site scripting (XSS) payloads. For example, injecting a script tag such as <script>prompt(/xss/);</script> into the 'id' parameter and observing if it executes in the browser indicates the presence of the vulnerability.

A practical way to test this is by accessing a URL like: http://127.0.0.1/pharmacy/index.php?page=product&id=<script>prompt(/xss/);</script> and checking if a prompt box appears, which confirms the XSS vulnerability.

Network or system administrators can also use web vulnerability scanners that support XSS detection to automate this process.


What immediate steps should I take to mitigate this vulnerability?
  • Implement proper output encoding to ensure user inputs are treated as text rather than executable code.
  • Strictly validate and sanitize user inputs, allowing only expected formats and rejecting or escaping potentially malicious content such as script tags.
  • Apply a strict Content Security Policy (CSP) to restrict sources of executable scripts and prevent unauthorized script execution.
  • Set the HttpOnly and Secure flags on sensitive cookies to prevent JavaScript access and ensure cookies are transmitted only over HTTPS.
  • Conduct regular security audits and code reviews to detect and address XSS and other vulnerabilities promptly.

Ask Our AI Assistant
Need more information? Ask your question to get an AI reply (Powered by our expertise)
0/70
EPSS Chart