Skip to content
Account takeover Write-up Intermediate

0-click Account Takeover via Punycode

The application treated a Unicode (Punycode) email address as identical to its ASCII lookalike, so an attacker could register the Punycode variant and trigger a password reset that was delivered to the attacker's own inbox. The attacker could then log in using the original ASCII email and the new password, taking over the victim's account without any interaction from the victim.

0x_s3fo Follow

Published on medium.com

بِسْ� ِ اللَّـهِ الرَّحْ� َـٰنِ الرَّحِي� ِ اللَّهُ� َّ صَلِّ وَسَلِّ� ْ وَبَارِكْ عَلَى سَيِّدِنَا � ُحَ� َّدٍ

Saif Eldin, 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 the application or database normalised or cast Unicode email addresses to ASCII, causing distinct addresses to be treated as identical during registration and password reset.

What the attacker needed

Attacker can register a Punycode email; victim has an account with the ASCII email; no victim interaction needed

The fix

The application should normalise email addresses consistently and reject or treat as distinct any Unicode lookalikes, ensuring password resets are sent only to the exact registered address.

How it was found

  1. Register and confirm a normal ASCII email account.
  2. Try to invite the Punycode version of that email to an organisation; the app says the user already exists.
  3. Submit the Punycode email in the password reset form.
  4. Receive the reset link at the Punycode address, click it, and set a new password.
  5. Log in using the original ASCII email and the new password to control the account.

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.

Websites often store email addresses as text. Some characters look the same but are actually different, like a normal 'a' and an 'à' with an accent. If a site treats these as the same email, an attacker can use the accented version to receive a password reset meant for the real account, then log in as the victim.

What is Account takeover?

Getting into someone else's account through a flaw in sign-in, password reset, second factor, single sign-on or session handling.

Similar reports

View all

Same bug class and techniques, clearest first.

Account takeover

The lesson behind this report.

Getting into someone else's account through a flaw in sign-in, password reset, second factor, single sign-on or session handling.