-
Notifications
You must be signed in to change notification settings - Fork 70
DANGEROUS_FUNCTIONS_JS_CHECK
The insertCSS and executeJavaScript functions allow injecting CSS and JavaScript, respectively, from the main process to the renderer process. Also eval, Function, setTimeout, setInterval and setImmediate allow JavaScript execution in the context of a BrowserWindowProxy. If the arguments are user-supplied, they can be leveraged to execute arbitrary content and modify the application behavior. This check detects the use of dangerous functions with dynamic arguments, and delegates the review to the user.
In a vulnerable application, a remote page could leverage these functions to subvert the flow of the application by injecting malicious CSS or JavaScript.
Search for occurrences of insertCSS, executeJavaScript, eval, Function, setTimeout, setInterval and setImmediate with user-supplied input in both BrowserWindow and webview tag configurations and all other JavaScript resources.