4 ms·
I was looking under security and I don’t see any mention of misuse, but that can also be hard to identify. Potential misuse should not stop WebGPU from moving
by mrweasel 5y ago
I was looking under security and I don’t see any mention of misuse, but that can also be hard to identify.
Potential misuse should not stop WebGPU from moving forward, but isn’t there a concern that the make JavaScript injection attacks more attractive? Rather than buying and operate a crypto mining setup it now becomes more attractive to attempt to utilize the GPUs of unsuspecting web users. Or am I misunderstanding how much of the GPU this will grant you access to?
- modeless 5y agoThe GPU is already accessible to JavaScript through WebGL. WebGPU should hopefully be somewhat faster in many cases, and simpler to use with a simpler/less buggy implementation. But it's not really exposing a ton of attack surface that's not already available in WebGL. Things like coin mining are already possible with WebGL, and a small-to-medium sized speed boost isn't going to change much. Neither WebGL nor WebGPU will today give you 100% of native (e.g. CUDA) performance for applications like coin mining or machine learning. And even WebGPU may never get all the way there, at least in a form that can be exposed in browsers, because top performance requires deep knowledge of the user's specific hardware configuration and specialized hardware-specific code paths. Exposing that to the web raises legitimate fingerprinting and portability concerns. That said, I think there is a lot of promise for WebGPU as a portable graphics API for native applications outside of browsers, where said fingerprinting and portability concerns are much less of an issue. In a native context, hardware-specific extensions could easily be exposed and there's no reason in theory why you couldn't have the best performance possible on any given hardware.
- Hizonner 5y ago> The GPU is already accessible to JavaScript through WebGL. Mine isn't. Disabling WebGL is DEFINITELY on the checklist for a new browser profile GPUs are way too complicated, way too opaque, and way too privileged to be safely exposed to the Web. We're not talking about some Web page using your machine to mine crypto here. We're talking about some Web page owning your kernel. Kill it with fire.
- modeless 5y agoWebGL has been part of browsers for many years now and the security track record is public. This fear has not proven true in reality. Overall, WebGL has not had more or worse security problems than other components of the browser. Great care has been taken to properly isolate and sandbox WebGL, far in excess of what any other graphics API has ever had in terms of security. WebGPU in browsers will have the same level of protection.
- jlokier 5y agoI visited a WebGL page a few years ago in Firefox on a laptop running Ubuntu, and it crashed the X server, taking down all other applications. I don't know of any other browser feature with that track record.
- incrudible 5y agoYour machine is way more likely to get owned through some bug parsing a dumb string. Anything your browser displays ends up in the graphics driver, one way or another. WebGL is arguably a much smaller surface to deal with than all the code involved in rendering a web page efficiently.
- paulgb 5y ago> I was looking under security and I don’t see any mention of misuse, but that can also be hard to identify. For what it's worth, the overall WebGPU spec draft (rather than the shader spec) has a section on security/malicious use: https://gpuweb.github.io/gpuweb/#malicious-use https://gpuweb.github.io/gpuweb/#malicious-use