Vulnerabilities/

Electerm runWidget has a path traversal that leads to arbitrary code execution

Severity:
High

Description

The runWidget function in src/app/widgets/load-widget.js constructs a file path by directly concatenating user‑supplied widget identifiers without any sanitisation:

Because runWidget is exposed to the renderer process via an asynchronous IPC handler with no input validation, an attacker who achieves JavaScript execution inside the renderer (for example, through a malicious plugin or a cross‑site scripting flaw in the built‑in webview) can abuse a path traversal (../) to load and execute an arbitrary JavaScript file anywhere on the victim’s filesystem.

Recommendation

Update the electerm package to the latest compatible version. Followings are version details:

References

Related Issues

Tags:
npm
electerm
Anything's wrong? Let us know Last updated on May 08, 2026