Skip to content
Account takeover Write-up Intermediate

Account Takeover via Unicode-Encoded Email

The backend mishandled Unicode homoglyphs in email addresses, allowing an attacker to use a lookalike address to reset the password of a legitimate account. This could lock out the real user and, if OTP were bypassed, lead to full account takeover.

medium.com

Published on medium.com

Recently, I explored a case where improper handling of Unicode homoglyphs in email addresses led to a serious authentication flaw.

BAPPAYNE, 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 backend applied Unicode normalization after uniqueness checks and used loose comparison rules, so homoglyph email addresses were mapped to the same account as the original.

Impact

An attacker could reset the password of a legitimate account, causing account lockout; if OTP were bypassed or intercepted, this could lead to full account takeover.

What the attacker needed

Target email address known; no OTP bypass needed for lockout

The fix

The application should convert Unicode domain names to punycode, restrict the local part to a safe ASCII subset, reject confusable input, and always send reset links only to the original registered email.

How it was found

  1. Identify a target account email address.
  2. Replace one ASCII character with a Unicode homoglyph to create a lookalike email.
  3. Use the homoglyph email in the Forgot Password flow.
  4. Reset the password.
  5. Observe that the real account is now bound to the new password.

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.

Email addresses can contain characters that look almost identical to normal letters, like 'ă' instead of 'a'. The system treated these lookalike addresses as the same as the real one, so an attacker could request a password reset for someone else's account using a fake address. This is dangerous because it can let an attacker take over the account or lock the real owner out.

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.