Scratch Desktop 3.17 – Cross-Site Scripting/Remote Code Execution (XSS/RCE)
CVE-2020-7750 was disclosed on Scratch's official forums on 21th of October 2020 by the forum user apple502j. The forum thread describes a cross-site scripting (XSS) vulnerability in Scratch and Scratch Desktop prior to 3.17.1. You can exploit the vulnerability by uploading a SVG (*.svg) file WITHOUT the viewBox attribute and embedding a malicious event handler. Example: <svg xmlns:xlink="http://www.w3.org/1999/xlink"><image href="doesNotExist.png" onerror="<INSERT JS PAYLOAD>" /></svg>. The malicious SVG can be uploaded as a sprite or stored within a Scratch project file (*.sb3), which is a regular ZIP archive by the way. The Scratch Desktop versions runs on Electron where the exploit can be used for remote code execution (RCE).