By using a form with a data URI it's possible to gain access to the privileged JSONView object that has been cloned into content.
A form submission to a data URI in a new tab briefly exposes a privileged JSONView object cloned into the content scope before the tab is closed. An attacker could hold a window reference and reach that privileged object, which the reporter describes as a stepping stone toward further exploitation.
Originally disclosed on Mozilla
- Fixed in 56 days
- Paid in 2 months
- Disclosed after 56 days
Created attachment 9074096
ObtainJSONView-testcase-new.html
I'm attaching a testcase that shows this work. When viewing the testcase click the submit button, and then open the console window and look at testWin.JSONView
The issue here is that defense in depth against data URIs in new tabs actually leaves a small window of time in which it is possible to gain a reference to a JSONView window/tab before it is closed.
This tab just leaves the JSONView Object that has been cloned into the content scope accessible from the window reference that is held.
I was planning to do more work on this seeing as this is a great stepping stone, but my situation and time right now aren't going to allow it.
In the past I believe we treated this as sec-high so yeah.
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 defence that closes data-URI tabs is asynchronous, so the privileged JSONView object cloned into the content scope remains reachable through a held window reference for a short period.
Impact
An attacker could reach the privileged JSONView object from content scope, which the reporter treats as a potential stepping stone, though the text does not demonstrate a full exploit.
What the attacker needed
Victim loads attacker-controlled page; browser with JSONView feature
How it was found
- Open the attached testcase page.
- Click the submit button, which opens a data-URI form result in a new tab.
- Open the console and inspect the held window reference's JSONView property.
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.
Some browser features add helper objects to a page so it can display things like formatted JSON. Normally a page opened from a special data link is shut down quickly for safety. Here the shutdown was not instant, so a script could grab a handle to the new window and still reach the helper object, which should not be reachable from ordinary page content.
What is Access control?
A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.