FirstBlood-#892Reflected XSS on the login form in the goto parameter
This issue was discovered on FirstBlood v2

On 2021-10-30, vigilante Level 4 reported:


There's a reflected XSS vulnerability on POST /login.php?action=login with the "goto" parameter.

I ran the param miner extension in Burp and it indicated that there's a "goto" parameter.

Identified parameter on goto

Steps to Reproduce:

  1. Visit /login.php?goto=javascript:confirm123
  2. Enter valid credentials to log in.
  3. After pressing the "Secure Login" button, our XSS payload will execute.


We are able to execute javascript in the victims browser.

P3 Medium

Endpoint: /login.php

Parameter: ?goto=

Payload: javascript:confirm`123`

FirstBlood ID: 39
Vulnerability Type: Reflective XSS

Our mistake: The parameter "goto" on login.php should of been "fixed" when redirecting to prevent XSS but due to an oversight from Sean and Karl, the new code did not make it into production. This has since updated since the event ended and you're recommended to re-try. It's related to bug ID 26 because the idea was developers fixed *this* one (when redirecting) but forgot the other reflection.