The scripting language JavaScript can utilize the resources of the graphics processing unit (GPU) of browsers via programming interfaces such as WebGL and the new WebGPU standard. However, there is risk involved.

Using a website with malicious JavaScript, researchers from the Institute of Applied Information Processing and Communications at Graz University of Technology (TU Graz) were able to spy on information about data, keystrokes and encryption keys on other people’s computers in three different attacks via WebGPU.

WebGPU is currently still under active development, but browsers such as Chrome, Chromium, Microsoft Edge and Firefox Nightly versions already support it. Thanks to its greater flexibility and modernized design compared to WebGL, the interface will end up widely used in the coming years.

“Our attacks do not require users to interact with a website and they run in a time frame that allows them to be carried out during normal Internet surfing. With our work, we want to clearly point out to browser manufacturers that they need to deal with access to the GPU in the same way as with other resources that affect security and privacy,” said Lukas Giner from the Institute of Applied Information Processing and Communications at TU Graz.

The research team carried out its attacks on several systems in which they installed different graphics cards from NVIDIA and AMD. The NVIDIA cards were from the GTX 1000 series and the RTX 2000, 3000 and 4000 series, while the AMD cards were from the RX 6000 series.

Schneider Bold

For all three types of attack, the researchers used the access to the computer’s cache memory available via WebGPU, which is for fast and short-term data access by the CPU and GPU. This side channel provided them with meta-information that allowed them to draw conclusions about security-relevant information.

The team was able to track changes in the cache by filling it themselves using code in the JavaScript via WebGPU and monitoring when they removed their own data from the cache by input.

This made it possible to analyze the keystrokes relatively quickly and accurately. By segmenting the cache more finely, the researchers were also able to use a second attack to set up their own secret communication channel, in which filled and unfilled cache segments served as zeros and ones and thus as the basis for binary code.

WebGPU opens the possibility for side channel attacks.
Source: Lunghammer – TU Graz


They used 1024 of these cache segments and achieved transfer speeds of up to 10.9 kilobytes per second, which was fast enough to transfer simple information. Attackers can use this channel to extract data they were able to attain using other attacks in areas of the computer disconnected from the Internet.

The third attack targeted AES encryption, which encrypts documents, connections and servers.

Here, too, they filled up the cache, but with their own AES encryption. The reaction of the cache enabled them to identify the places in the system responsible for encryption and access the keys of the attacked system.

“Our AES attack would probably be somewhat more complicated under real-time conditions because many encryptions run in parallel on a GPU,” said Roland Czerny from the Institute of Applied Information Processing and Communications at TU Graz. “Nevertheless, we were able to demonstrate that we can also attack algorithms very precisely. We did of course communicate the findings of our work to the browser manufacturers in advance and we hope that they will take this issue into account in the further development of WebGPU.”

Pin It on Pinterest

Share This