Reflected XSS at https://da.wordpress.org/themes/?s= via "s=" parameter
The search parameter on a WordPress themes page reflected user input without proper encoding, allowing an attacker to inject a script. An attacker could craft a link that executes arbitrary JavaScript in a victim's browser.
Originally disclosed on HackerOne
- Triaged in under an hour
- Fixed in 13 days
- Paid in 28 days
- Disclosed after 3 months
Hello -
You have a reflected XSS vulnerability located at this domain:
https://da.wordpress.org/themes/?s=
This was tested on the latest version of Chrome (Version 57.0.2987.133 (64-bit)
By entering this payload in the URL, you are able to execute a script to fire:
1%3C!%27/*%22/*\%27/*\%22/*--%3E%3C/Script%3E%3CImage%20Srcset=K%20*/;%20Onerror=confirm1%20//%3E#
Note that the "1" in the confirm is enclosed in backticks, the HackerOne editor just makes it difficult to show. I have attached a screenshot to show the full URL, as well as included it below:
https://da.wordpress.org/themes/?s=1%3C!%27/*%22/%27/%22/--%3E%3C/Script%3E%3CImage%20Srcset=K%20/;%20Onerror=confirm1%20//%3E#
Please let me know if you have any other questions, thanks!
Attachments


Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the search parameter is reflected into the page without proper output encoding or sanitisation.
Impact
An attacker could execute a script in a victim's browser via a crafted link.
What the attacker needed
Victim clicks a crafted link
How it was found
- Open the themes search page on the Danish WordPress site.
- Insert the crafted payload into the 's' query parameter of the URL.
- Load the URL in a browser to trigger the script execution.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
A reflected XSS flaw means the site puts the search term from the address bar onto the page without cleaning it, so an attacker can include code the browser runs as if from the site.
What is XSS?
Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.