SourceCodester Simple and Nice Shopping Cart SQL Injection Vulnerability

Vulnerability

A SQL injection vulnerability exists in SourceCodester Simple and Nice Shopping Cart Script version 1.0, specifically within the '/signup.php' file. The issue arises from inadequate validation of the 'username' parameter in POST requests, allowing attackers to inject malicious SQL code that is executed without proper sanitization. This vulnerability can be exploited remotely, without the need for authentication, potentially leading to unauthorized access to the database, manipulation or deletion of data, and exposure of sensitive information.

Impact

Exploitation of this vulnerability allows for SQL injection, which could be used to access, modify, or delete database information. Such actions could disrupt services and compromise overall system security.

Reproduction

To reproduce this vulnerability, send a POST request to the '/signup.php' endpoint with a crafted 'username' parameter that includes malicious SQL payloads. The injection can be verified by observing the application's response or by using a tool like sqlmap to automate the exploitation process.

Remediation

It is recommended to use prepared statements and parameter binding to prevent SQL injection. Additionally, input validation and filtering should be implemented to ensure user input meets expected formats. Minimizing database user permissions and conducting regular security audits can also help mitigate such vulnerabilities.

Added: Feb 25, 2026, 5:22 AM
Updated: Feb 25, 2026, 5:22 AM

Vulnerability Rating

Custom Algorithm
spread
1.0
impact
3.1
exploitability
9.7
remediation
0.0
relevance
3.4
threat
6.4
urgency
2.9
incentive
8.3

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.