Skip to content
XSS Write-up Beginner

How Instagram Helped Me To Exploit XSS 🔥

The target site fetched an Instagram profile picture and displayed it, and the Instagram display name was not sanitised, so an XSS payload in the name executed when the profile was opened in a new tab. An attacker could run script in the context of the target site.

Farhan Follow

Published on infosecwriteups.com

AssalamuAlaikum Everyone. My Name is Farhan aka Fani Malik, a Bug Hunter.

Farhan, on infosecwriteups.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 execute arbitrary JavaScript in the context of the target site when a victim opens the crafted profile link, potentially leading to account compromise or data theft.

What the attacker needed

Control over an Instagram profile name; victim opens the crafted profile link

How it was found

  1. Set an XSS payload as the Instagram profile name.
  2. Enter the Instagram username in the target site's username field.
  3. Select the profile, right-click, and open the link in a new tab.
  4. The XSS payload executes.

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) is when a website shows user-supplied text without cleaning it, so a script hidden in that text runs in a visitor's browser. Here, the site copied an Instagram profile name into its own page without cleaning it, so a script in the name ran when the profile was opened.

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.