Reflected XSS on taskbook.nasaprs.com via `errmsg` parameter (filter bypass using unclosed tag)
The errmsg query parameter was reflected into the HTML response without output encoding, and a server-side filter only stripped complete tags. An attacker could supply an unclosed tag to bypass the filter and execute arbitrary JavaScript in a victim's browser.
Originally disclosed on Bugcrowd
- Accepted in 38 hours
- Fixed in 19 days
- Disclosed after 31 days
Summary by 0xsuryakiran
Summary:
The errmsg query parameter is reflected into the HTML response without output encoding. A server-side filter attempts to strip <...> sequences, but it only matches tags that contain a closing >. By supplying an unclosed tag, the filter is bypassed and arbitrary HTML/JS executes in the victim's browser.
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
The parameter was reflected without output encoding, and the input filter only matched complete tags ending in a closing angle bracket, so an unclosed tag bypassed it.
Impact
An attacker could execute arbitrary JavaScript in a victim's browser, though the text does not describe any specific consequences beyond code execution.
What the attacker needed
Victim clicks a crafted link
How it was found
- Send a request to the errmsg parameter with an unclosed tag containing script.
- Observe that the filter does not strip the unclosed tag.
- The browser renders the injected markup and executes the script.
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.
When a website puts something you typed into its page without cleaning it first, you can sometimes type code instead of text. Here the site tried to remove dangerous tags but only removed ones that were properly closed, so an unfinished tag slipped through and ran code in the visitor'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.