Same-Origin Policy Bypass Image Size Leak in Drag and Drop
A drag-and-drop feature in Firefox allowed a page to learn the dimensions of an image from another origin, bypassing the Same-Origin Policy. An attacker could use this to leak the size of an image the victim drags onto a malicious page.
- Fixed in 4 days
- Paid in 9 days
- Disclosed after 4 days
Created attachment 9314748 poc.html
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/109.0.0.0 Safari/537.36
Steps to reproduce:
Title
- Same-Origin Policy Bypass Image Size Leak in Drag and Drop
Summary
- A Same-Origin Policy Bypass vulnerability exists in the Drag and Drop
- If this vulnerability is exploited, it is possible to bypass the Same-Origin Policy and leak the size of the Image.
Test environment
- Product : Mozilla Firefox 109
- OS : Windows 10 (21H2), macOS Ventura 13.2
Proof-of-Concept
- Please check the attached file!
Reproduce
- Open the server and access the poc page.
- When you drag and drop an image, the size of the image is leaked.
CREDIT Information
- Dohyun Lee (@l33d0hyun) of SSD Labs
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 drag-and-drop handling exposed image dimensions from a cross-origin image without checking the origin.
Impact
A malicious page could learn the dimensions of a cross-origin image the victim drags onto it, a minor information leak; the report does not show any wider compromise.
What the attacker needed
Victim drags an image onto the page; attacker hosts a proof-of-concept page
How it was found
- Open the server and load the proof-of-concept page.
- Drag and drop an image onto the page.
- Observe that the image's size is leaked.
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.
Websites are normally kept apart by a rule called the Same-Origin Policy, so one site cannot read data from another. Here, dragging an image onto a page let that page find out how wide and tall the image was, even though it came from a different site. That small piece of information should have stayed private.
What is Info disclosure?
Data the application should keep private (personal data, internal details, other users' records) reaches someone it should not.