Resource exhaustion by creating very large DOM from loop
Categories
(Core :: DOM: Core & HTML, defect)
Tracking
()
People
(Reporter: alisyarief.404, Unassigned)
References
Details
(Keywords: dupeme, reporter-external, Whiteboard: [reporter-external] [client-bounty-form] [verif?])
Attachments
(1 file)
|
504 bytes,
text/html
|
Details |
Memory Leaks Firefox Browser
A memory leak in a browser can occur when JavaScript code or Firefox Browser allocate memory for use, but fail to properly release it when it is no longer needed. This can cause the browser to use more and more memory over time, eventually leading to performance issues or even crashing.
Repro Steps
macOS Monterey : 12.6.2 (21G320)
Firefox Version : 108.0.1 (64-bit)
Victim Click "Create Elements" button and then create a large number of div elements and append them to the container element.
This elements are never removed from the DOM, Firefox Browser will continue to allocate memory for them even though they are no longer needed.
As a result, the browser's memory usage will increase with each click of the button, potentially leading to a memory leak.
File Script in Attachment
Video POC : https://drive.google.com/file/d/1_SiuzsojtyAs86tdmQDR7ncZKl9iJMBx/view?usp=sharing
Thanks
Comment 1•3 years ago
|
||
Resource exhaustion is not a security problem in browsers. This is a common pattern in today's "infinite scroll" style web applications. Browsers need to strike a balance between punishing "greedy" pages (killing them is often the only workable choice) and showing the user as much of the content they requested as possible.
Different browsers balance things in different ways and at different times (e.g. how often does the "garbage collector" run?) but this testcase should behave similarly on all browsers.
Updated•3 years ago
|
Updated•3 years ago
|
Updated•3 years ago
|
Updated•2 years ago
|
Description
•