SourceCodester Best House Rental Management System SQL Injection Vulnerability

Vulnerability

A SQL injection vulnerability has been identified in SourceCodester Best House Rental Management System version 1.0. The issue resides in the 'login2' function of the '/admin_class.php' file, where the 'username' parameter is improperly validated, allowing remote attackers to inject malicious SQL queries. This vulnerability could lead to unauthorized database access, data manipulation, 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. Additionally, such vulnerabilities can often be leveraged to execute administrative operations on the database or, in some cases, gain command execution on the server.

Reproduction

The vulnerability can be reproduced by sending a POST request to '/ajax.php?action=login2' with a crafted 'username' parameter that includes SQL injection payloads. This can be done using tools like sqlmap, which automates the process of finding and exploiting SQL injection vulnerabilities.

Remediation

It is recommended to use prepared statements and parameter binding to prevent SQL injection, validate and filter user input, minimize database user permissions, and conduct regular security audits.

Added: Oct 27, 2025, 3:20 AM
Updated: Oct 27, 2025, 3:20 AM

Vulnerability Rating

Custom Algorithm
spread
0.0
impact
7.5
exploitability
6.0
remediation
0.0
relevance
0.8
threat
6.4
urgency
2.9
incentive
1.7

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