Human Connection Challenge: Season 1 – Web Exploitation - XSS
Question: Identify a reflected XSS vulnerability on the web application that reveals a token in the error message.
There are a few forms on the web page:
- / -> submit reloads /, the attachment isn't even uploaded => no user input displayed
- /register -> submit loads / => no user input displayed
- /member-login -> submit reloads the page with the entered data => user input. But it seems impossible to get working script tags though
- /<another login page> -> submit loads yet another static page => no user input displayed
There's also a path traversal, however it seems impossible to e.g. execute a command to update a field the database. And there's SQL injection, and it seems impossible to insert/update a field in the database.
Still, my best guess would be to insert a user "<script>alert()</script>" in the database. Then I can display the user list to trigger the script.
Any hints on where to go?
For the XSS, I would recommend you to test all of the available fields, one of them is the one and you should see the token in the same page, if it redirects to the main page, then that was not the correct field. Tip, try your script in all the fields at the same time!
Directory Traversal, you need to find a url with something like /test?field=something.txt, this could be an indicate of path traversal.
For SQL, only extract data is possible no modifications are allowed.