[scores.ubnt.com] DOM based XSS at form.html
A DOM-based cross-site scripting flaw remained in a form page after a previous fix added a tag-stripping function. An attacker could inject JavaScript through a parameter value without HTML tags, triggered by a mouseover event on the page header.
- Triaged in 14 days
- Fixed in 5 months
- Paid in 5 months
- Disclosed after 6 months
Hello,
I would like to report that the #130889 bug hasn't been fixed completely.
The removeTags function has been added, however an attacker is still able to inject Javascript as parameter values without any HTML tags:
https://scores.ubnt.com/form.html?uid=1&p=%27%20onmouseover=alert(document.domain)//
The script is triggered by the onmouseover event on the header.
Tested with latest Firefox and Chrome.
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 removeTags function only stripped HTML tags and did not neutralise JavaScript placed in attribute values, so injected event handlers still executed.
Impact
An attacker could execute arbitrary JavaScript in a victim's browser in the context of the site, though the report only demonstrates an alert of the domain.
What the attacker needed
Victim visits a crafted link; victim moves mouse over the header
How it was found
- Open the form page with a crafted uid and p parameter containing a quote and an onmouseover handler.
- Move the mouse over the page header to trigger the injected event.
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.
The page takes a value from the web address and puts it into the page without cleaning it properly. A previous fix only removed HTML tags, but an attacker can still insert JavaScript that runs when the user moves the mouse over the header. This lets the attacker run code in the victim's browser.
What is XSS?
Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.