Skip to content
XSS Write-up Intermediate

Part 1: How I dumped 5,000,000 emails by reading admin panel JS c

The report describes several cross-site scripting flaws: a reflected XSS in an unverified-email message parameter, stored XSS via username changes on the website, stored XSS through usernames rendered in comments, and HTML injection into password-reset emails. An attacker could run script in a victim's browser or craft phishing emails, though a WAF blocked some payloads.

alimuhammadsecured Follow

Published on medium.com

So I was bored one day during winter break and began looking at security disclosures for websites. I stumbled upon one that looked kind of interesting, this app was fitness-related.

Alimuhammadsecured, on medium.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

Root cause

Likely inconsistent input sanitisation across API routes and templates, where some paths HTML-encoded user input and others did not.

Impact

An attacker could run script in a victim's browser via reflected or stored XSS, and could inject HTML into password-reset emails for phishing; a WAF blocked some reflected payloads and the blind XSS callback could not be reproduced.

What the attacker needed

A free account; victim views a crafted link or page; WAF bypass for some payloads

How it was found

  1. Register an account, log out, then try logging in without verifying the email.
  2. Observe the unverified-email message with a resendemail parameter containing the email address.
  3. Change the parameter value to an XSS payload and reload.
  4. For stored XSS, change the username on the website to an HTML payload.
  5. Make a comment so the username is rendered above it, then refresh.
  6. For email injection, set the username to HTML, request a password reset, and view the email.

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.

Cross-site scripting (XSS) lets an attacker slip their own JavaScript into a page other people view, so it runs in the victim's browser. Here, the site put user-supplied text into web pages and emails without cleaning it, so script could run. A web application firewall (WAF) is a filter that tries to block such input, and it stopped some attempts.

What is XSS?

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

More by alimuhammadsecured

View all

5 more disclosed reports, best first.

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.