This lab contains a vulnerability in the search blog functionality. The reflection occurs inside a template string with angle brackets, single, and double quotes HTML encoded, and backticks escaped. To solve this lab, perform a cross-site scripting attack that calls the alert
function inside the template string.
After accessing the lab, I sent the search request to Burp Suite for further analysis:
In the response, I noticed that my input data is being passed to a script:
Since angle brackets, single quotes, double quotes, backslashes, and backticks are Unicode-escaped, I used embedded expressions ${...}
that will be executed when the template literal is processed.
By injecting the following payload:
I triggered an alert popup, successfully solving the lab.