It’s no wonder that people are often wondering which the most secure browser is. Browsers are often leveraged in various attack scenarios, and even an updated browser can fall victim to attackers.
One of the recent serious security issues that involves both Google Chrome and Mozilla Firefox could lead to the compromise of several security features in the browsers and spoof URLs in the address bar via a simple trick. The discovery’s author is security researcher Rafay Baloch. Luckily, the issues are already fixed but other vendors still need to work on fixing them. In addition, Baloch said that he got paid a bug bounty in the size of $5,000 on behalf of Google.
The RTL-LTR URL Spoofing Issue Explained
The issue comes from the way browsers line up URLs written with mixed RTL (Arabic) and LTR (Roman) characters.
Characters from languages are such as Arabic, Hebrew are displayed from RTL (Right To Left) order, due to mishandling of several unicode characters such as U+FE70, U+0622, U+0623 etc and how they are rendered combined with (first strong character) such as an IP address or alphabet could lead to a spoofed URL.
The researcher noticed that when he placed neutral characters like “/” in the filepath which caused the URL to flip and display from right to left. For the URL to be spoofed, the URL needs to begin with an IP address followed by neutral characters. This is because the omnibox recognizes the IP address as a combination of punctuation and numbers. Because the LTR (Left To Right) direction isn’t applied properly, this leads to the entire URL be rendered from RTL (Right To Left).
The RTL-LTR Spoofing Flaw Easy to Exploit
The worst part is that the spoofing issue is very easy to exploit, especially in phishing attacks. An attacker could take the server’s IP address, add some Arabic characters and affix the domain of a legitimate website. The produced URL can be embedded in spam and can be sent out in emails, SMS and IM messages. Upon clicking, the user will be redirected to a page that displays a credible domain but in fact is on a bad server.
Furthermore the address part can be easily hidden, especially on mobile browsers, by choosing a longer URL to make the attack more realistic, Baloch says.
In Firefox, the same issue has been identified as CVE-2016-5267. However, the exploit itself is slightly different due to Mozilla’s different codebase.