FirstBlood-#912DOM xss found on management portal
This issue was discovered on FirstBlood v2.0.0 (issues patched)



On 2021-10-30, vishal Level 2 reported:

Discription:stored xss in message left at the time of cancelation of appointment.

Steps to Reproduce:
  1. visit /book-appointment.php & create an apointment.

  2. copy appointment id you will recieve.

  3. visit /yourappointments.php and using your appointment id retrieve appointment.

  4. now click on modify appointment and capture request in proxy & send it to repeater tab.

  5. Now you will need to make some changes into request add message=';alert(document.cookie)' in request as below .

  6. Now All you need to do is reload step 4 web page.

All done you should probably get stored xss popup just as me on this page .

In any case if something is missing Just let me know - Vishal

P2 High

Endpoint: /book-appointment.php

Parameter: message

Payload: ';alert(document.cookie)'


FirstBlood ID: 22
Vulnerability Type: Stored XSS

Whilst an attempt was made to fix the stored XSS vulnerability in managing an appointment, it actually introduced new issues such as when creating and editing and not just when cancelling the appointment. Making use of htmlentities() and relying on .value() in javascript to encode certain characters does not prevent XSS overall. The 'fix' to this issue also results in it being vulnerable to admins on cancelled appointments as well.