QR code user confirmation bypass with invalid protocol
The iOS Firefox QR code scanner skipped its usual user confirmation prompt when a QR code contained a specially crafted URL, so the browser opened the site automatically. An attacker could use this to send a victim to a phishing or malware page without any consent step.
Originally disclosed on Mozilla
- Fixed in 22 days
- Paid in 22 days
- Disclosed after 22 days
Created attachment 9459339 The video POC shows that the browser behaves normally and asks for user consent when normal QR code is used. But the user confirmation gets bypassed with malicious url inside qr code.
Description A vulnerability exists in the iOS firefox browser's QR code scanning feature that allows an attacker to bypass the user confirmation prompt. The browser typically scans a QR code and prompts the user for confirmation before redirecting them to the website. However, by crafting a specially designed URL, an attacker can exploit this vulnerability to bypass the confirmation step entirely. This allows the user to be automatically redirected to a malicious website without their consent, leading to phishing attacks, malware installation, stealing sensitive information or other malicious activities.
Steps to Reproduce
- Open the firefox browser app in iOS device.
- Tap on QR code scanner to scan the QR code.
- Notice that the browser asks for user consent/confirmation before opening the non-malicious website.
- Now, craft a malicious QR code and notice that the browser does not asks for user consent/confirmation before opening the malicious website, thus bypassing the user confirmation.
FIX The browser needs to check if the URL is valid or not. Enforce strict user confirmation before proceeding to a link.
Reference https://hackerone.com/reports/1946534
The android app is not vulnerable to this attack as the android app says "web address not valid" when malicious QR code is scanned.
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 scanner treated the crafted URL as invalid or non-navigable and fell through to a code path that opened it without the confirmation check.
Impact
A victim could be redirected to a phishing or malware site without consent, though the report gives no proof beyond the missing prompt and notes the Android app rejects the same code.
What the attacker needed
Victim scans a crafted QR code; iOS Firefox app
The fix
The scanner should validate the URL and always enforce the confirmation prompt before navigating; the text does not say a fix shipped.
How it was found
- Open the Firefox app on an iOS device.
- Tap the QR code scanner and scan a QR code.
- Observe that a normal QR code triggers a consent prompt before the site opens.
- Scan a QR code holding a crafted URL and observe that no consent prompt appears and the site opens.
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 scan a QR code in a browser, the app normally shows the address and asks if you want to open it. Here, a cleverly built address made the app skip that question and open the page straight away. That matters because the question is the only moment a person can refuse to visit a harmful site.
What is Mobile?
Flaws specific to Android and iOS apps: exported components, deep links, WebViews and data left on the device.