Skip to content
Access control Write-up Intermediate

How I De-Anonymized Instagram Users Through Facebook Services

Instagram's Action Button update endpoint accepted an unvalidated URL paired with Facebook's appointment App ID, so a crafted Book button could send a visitor's Instagram identifier to an attacker's server. That identifier could then be exchanged at a Facebook appointment endpoint for the user's name, email address or phone number.

Pouya Follow

Published on darabi.me

I discovered a vulnerability chain in Instagram and Facebook services that allowed me to de-anonymize Instagram users and retrieve personally identifiable information, including their name, email address, and phone number.

Pouya, on darabi.me

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

The URL validation and the update that saved the Action Button were separate operations, and the update endpoint trusted the client to resubmit only a URL that had already passed validation.

Impact

An attacker could de-anonymise an Instagram user who clicked the Book button and obtain their name, email address or phone number; the text does not say whether a defence limited this.

What the attacker needed

Instagram business account with Action Buttons; victim clicks the Book button; attacker-controlled server

The fix

The update endpoint should have independently validated that the URL belonged to the allowed scope of the supplied App ID, rather than trusting the earlier validation step.

How it was found

  1. Send the update request directly with Facebook's appointment App ID and an attacker-controlled URL.
  2. A visitor clicks the Book button on the Instagram profile.
  3. Instagram navigates to the attacker URL without showing Linkshim and includes the Instagram user identifier.
  4. The attacker's server extracts the identifier and queries Facebook's appointment endpoint.
  5. The response returns the user's name, email address or phone number.

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.

Instagram lets business accounts add a 'Book' button that links to an outside service. The server checked the link once but then trusted the app to send the same link again later, so an attacker could swap in their own web address. When a visitor clicked Book, Instagram passed along a hidden user ID, which the attacker traded for the person's real name, email or phone number.

What is Access control?

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.

More by Pouya

View all

5 more disclosed reports, best first.

Similar reports

View all

Same bug class and techniques, clearest first.

Broken access control

The lesson behind this report.

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.