|
|
|
|
|
by noodlesoups
2107 days ago
|
|
It's impossible to make any sane limits that would universally apply to web pages. An isolated environment for an arbitrary application is the web's purpose, not just loading a text document. You can actually play hw-accelerated doom3 on a browser today no problems. No add-ons, no nothing needed. |
|
For example, start the RAM at 12 times the number of CSS pixels. When the limit is hit, freeze the allocations until the user authorizes a doubling of the limit. Web sites would need about 10 authorization clicks to go from 4 MiB to 4 GiB. That goes for everything on the page, all sharing the limit.
Web sites would quickly change to minimize that, out of fear that users might not keep accepting the resource usage.
CPU usage could be similar, probably based on threads. The default is that only a single tab in a single window gets any time at all. Everything else is suspended. Users can grant permission for stuff like music players.
Network usage would also need to be limited, though limiting the RAM and CPU will tend to limit network usage as a side effect.