Skip to content
Info disclosure Disclosed report Intermediate CVE-2021-4221

Address Bar Spoofing due to Arabic RTL characters

The address bar in Firefox for Android misrenders URLs containing Arabic right-to-left characters, causing the displayed domain to appear as a trusted site (e.g., mozilla.org) while the actual content comes from a different domain. An attacker could exploit this to spoof the address bar and trick users into believing they are on a legitimate site.

Rohan Sharma Follow

Originally disclosed on Mozilla

  • Fixed in 10 months
  • Paid in 10 months
  • Disclosed after 10 months
Text
Created attachment 9215018
firefox-android-poc.html

User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Firefox/78.0

Steps to reproduce:

STEP 1: Click on "run" in attached file ("firefox-desktop-PoC.html")
The address bar will point to "www.mozilla.org", however the actual content is being delivered by "اختبار.اختبار"

The URL is not handled properly. Arabic characters in the domain name are being rendered from Right to Left(RTL) direction rather than Left to Right(LTR).


Actual results:

http://www.mozilla.org/hello/1/index.html/رابتخا.رابتخا


Expected results:

http://اختبار.اختبار/www.mozilla.org/hello/1/index.html
The address bar should point to "اختبار.اختبار" instead of "www.mozilla.org"

The original report as published on Mozilla's Bugzilla, by Rohan Sharma. Images and videos are our own copies; raw HTML is shown as text. View it on Mozilla's Bugzilla.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely the browser's URL rendering does not properly handle bidirectional text, allowing right-to-left characters to visually reorder the domain and path.

Impact

An attacker could spoof the address bar to make a malicious site appear as a trusted domain, potentially leading to phishing or credential theft.

What the attacker needed

Victim uses Firefox for Android; victim visits a crafted URL

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 report has not been written yet. The Original tab links to the source.

When you visit a website, the address bar shows the site's name. This report found that if a web address contains Arabic characters, Firefox displays it in a confusing order, making it look like you are on a different, trusted website. An attacker could use this to make a fake site look real and steal information.

What is Info disclosure?

Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.

More from Mozilla

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Information disclosure

The lesson behind this report.

Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.