SourceCodester Hospitals Patient Records Management System
- V1.0
A SQL injection vulnerability has been identified in SourceCodester Hospitals Patient Records Management System version 1.0. The issue arises in the file '/classes/Master.php' within the 'save_patient_history' function, where the 'id' parameter is not properly validated, allowing remote attackers to inject malicious SQL queries. This vulnerability could lead to unauthorized database access, data manipulation, and exposure of sensitive information.
Exploitation of this vulnerability allows for SQL injection, enabling attackers to interfere with the application's database queries. This could result in unauthorized data access, data modification or deletion, and in some cases, executing administrative operations on the database.
The vulnerability can be reproduced by sending a POST request to '/classes/Master.php?f=save_patient_history' with a crafted 'id' parameter that includes malicious SQL payloads. This can be done using tools like SQLMap, which automates the process of finding and exploiting SQL injection vulnerabilities.
To address this vulnerability, it is recommended to implement prepared statements and parameter binding to prevent SQL injection. Additionally, input validation and filtering should be applied to ensure user input conforms to expected formats. Minimizing database user permissions and conducting regular security audits can also help enhance the application's overall security.
Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.