CVE-2026-7282
Received Received - Intake
SQL Injection in SourceCodester Pharmacy System Enables Remote Exploit

Publication date: 2026-04-28

Last updated on: 2026-04-29

Assigner: VulDB

Description
A vulnerability was identified in SourceCodester Pharmacy Sales and Inventory System 1.0. This affects the function delete_expired of the file /ajax.php?action=delete_expired. The manipulation of the argument ID leads to sql injection. It is possible to initiate the attack remotely. The exploit is publicly available and might be used.
CVSS Scores
EPSS Scores
Probability:
Percentile:
Meta Information
Published
2026-04-28
Last Modified
2026-04-29
Generated
2026-05-07
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-74 The product constructs all or part of a command, data structure, or record using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify how it is parsed or interpreted when it is sent to a downstream component.
CWE-89 The product constructs all or part of an SQL command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended SQL command when it is sent to a downstream component. Without sufficient removal or quoting of SQL syntax in user-controllable inputs, the generated SQL query can cause those inputs to be interpreted as SQL instead of ordinary user data.
Attack-Flow Graph
AI Powered Q&A
Can you explain this vulnerability to me?

CVE-2026-7282 is a SQL injection vulnerability found in version 1.0 of the SourceCodester Pharmacy Sales and Inventory System. It exists in the file /ajax.php when accessed with the parameter action=delete_expired. The vulnerability arises because the id parameter is not properly validated or sanitized, allowing attackers to inject malicious SQL code.

This flaw can be exploited remotely without requiring user authentication or authorization. Attackers can manipulate the id parameter to perform unauthorized database operations such as leaking, modifying, or deleting data, and potentially gaining full control over the system.


How can this vulnerability impact me? :

Exploitation of this vulnerability can lead to significant security risks including exposure of sensitive information, compromise of data integrity, and disruption of service.

  • Unauthorized access to confidential data stored in the database.
  • Modification or deletion of critical data, affecting business operations.
  • Potential full system compromise if attackers gain control through the database.
  • Service disruption due to malicious database operations.

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

The vulnerability can be detected by testing the /ajax.php endpoint with the parameter action=delete_expired and manipulating the id parameter to check for SQL injection.

A proof-of-concept involves a boolean-based blind SQL injection attack using the id parameter to confirm the presence of the vulnerability.

Tools like sqlmap can be used to automate detection and exploitation attempts against the id parameter.

  • Example sqlmap command: sqlmap -u "http://target/ajax.php?action=delete_expired" --data="id=1" --method=POST --dbs

What immediate steps should I take to mitigate this vulnerability?

Immediate mitigation steps include:

  • Use prepared statements with parameter binding to prevent SQL injection by separating SQL code from user input.
  • Implement strict input validation and filtering to ensure the id parameter conforms to expected formats.
  • Limit database user permissions to the minimum necessary, avoiding use of high-privilege accounts such as root or admin for routine operations.
  • Conduct regular security audits of code and systems to detect and address vulnerabilities promptly.

How does this vulnerability affect compliance with common standards and regulations (like GDPR, HIPAA)?:

The SQL injection vulnerability in the Pharmacy Sales and Inventory System allows attackers to perform unauthorized database operations such as data leakage, modification, and deletion. This can lead to exposure of sensitive information and compromise data integrity.

Such unauthorized access and potential data breaches can negatively impact compliance with common standards and regulations like GDPR and HIPAA, which require protection of personal and sensitive data, ensuring confidentiality, integrity, and availability.

Failure to address this vulnerability could result in violations of these regulations due to unauthorized disclosure or alteration of protected data.


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