Bypassing IE's XSS Filter with showModalDialog
The author found that Internet Explorer's XSS filter could be bypassed by injecting JavaScript that sets the returnValue property of a modal dialog opened with showModalDialog. This allowed an attacker to read sensitive data such as a token or cookie from the vulnerable page and display it in an alert after the dialog closed.
The original lives on mksben.l0.cm
We do not hold its text, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Impact
An attacker could read sensitive information such as a token or cookie from the vulnerable page and display it, but the exploit required Internet Explorer and a redirect.
What the attacker needed
Internet Explorer; XSS in a string literal; Victim visits attacker page
How it was found
- Open the proof-of-concept page in Internet Explorer.
- The page redirects to a vulnerable page with a crafted query string that injects JavaScript setting returnValue to a sensitive value.
- Close the modal dialog to see the stolen token in an alert.
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 write-up has not been written yet. The Original tab links to the source.
A cross-site scripting (XSS) filter is a browser feature that tries to block malicious scripts injected into a page. The author showed that in old Internet Explorer, a script could still run and use a special function called showModalDialog to copy secret information from the page into a pop-up window, which then displayed it. This means the filter did not stop the attack.
What is XSS?
Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.