Skip to content
XSS Write-up Intermediate

Account Takeover via iFrame Injection

The language parameter on a store subdomain was vulnerable to HTML injection, allowing an attacker to inject an iframe that displayed a fake login form. An attacker could capture victims' credentials by tricking them into submitting the form.

xbforce Follow

Published on github.com

History

xbforce (@xbforce), on github.com

The full write-up lives on its author's site

It belongs to its author, 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 capture victims' credentials by displaying a fake login form in an iframe, potentially leading to account takeover.

What the attacker needed

Victim clicks a link; attacker hosts a malicious page

How it was found

  1. Create an index.html file with a form to get username and password of the victim, and redirect them to done.html.
  2. Create another file named done.html to show the unfortunate message.
  3. Make a directory and copy the index.html, done.html and the logo file of the target to the directory.
  4. Run both tools in the same directory where the files are located.
  5. Open the malicious URL as a victim and submit the form.
  6. Check the captured credentials in python SimpleHTTPServer:

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.

The website had a flaw that let an attacker insert their own webpage inside the real page. The attacker made it look like a login box, so users might type their password into the attacker's form. This is dangerous because the attacker can then steal those passwords.

What is XSS?

Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.

Similar reports

View all

Same bug class and techniques, clearest first.

Cross-site scripting (XSS)

The lesson behind this report.

Script an attacker supplies runs in another user's browser, on the target's origin, with that user's session.