Invoke Element.requestFullscreen then navigate to page on bfcache wouldn't show fullscreen security notification
Firefox would enter fullscreen mode without showing the usual fullscreen security notification when a page requested fullscreen and then navigated to a page restored from the back-forward cache. An attacker could use this to spoof the browser's address bar UI, since the user would not be told the page had gone fullscreen.
Originally disclosed on Mozilla
- Fixed in 24 days
- Paid in 42 days
- Disclosed after 24 days
Created attachment 9241190 fullscreen-spoof-form.html
After call element.requestFullScreen() then subsequently navigate to page in bfcache (e.g. using HTMLFormElement.submit(), location.href, or window.location.back(), and etc.) the browser goes into fullscreen without any fullscreen notification ("<domain> is now in fullscreen") as user unaware page displayed fullscreen it can leads to address bar UI spoofing.
I've tested this it works everytime I pressed the requestFullScreen button on the testcase using Windows 10 (on my laptop and VM). However on Linux (tested on KDE and GDM) it still require couple of button click to successfully turn browser into fullscreen.
When checking with mozregression I found the browser goes into fullscreen without security notification is after commit Bug 1669961 - Return null from .contentWindow when inner window is inactive. I observe before the commit Firefox will exit the fullscreen mode instead of goes into fullscreen.
Steps to reproduce:
- Visit attached fullscreen-spoof-form.html
- Click "requestFullScreen" button
- Browser goes into fullscreen without any fullscreen notification
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 a change in how inactive inner windows are handled meant the fullscreen state survived a navigation to a bfcache page without re-triggering the security notification.
Impact
The user could be shown a fullscreen page with no warning, enabling address bar UI spoofing; the reporter notes it worked reliably on Windows but needed several clicks on Linux.
What the attacker needed
Victim visits a crafted page; victim clicks a button; navigation to a bfcache page
How it was found
- Open the attached test page.
- Click the requestFullScreen button.
- The browser enters fullscreen with no security notification shown.
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 a website goes fullscreen, browsers normally show a warning so you know the page is now covering your whole screen. This report found a way to skip that warning by navigating to a page kept in the browser's memory (the back-forward cache, which saves pages so going back is fast). Without the warning, a malicious page could draw fake browser controls and trick the user.
What is UI spoofing?
The interface lies to the user: a framed page catches their clicks, or a browser shows the wrong address or a fake prompt. Paid when it leads to a sensitive action or convincing phishing.