Electerm
electerm: Path Traversal in Zmodem and Trzsz Download Filename Handling
electerm is an open-sourced terminal/ssh/sftp/telnet/serialport/RDP/VNC/Spice/ftp client. Prior to 3.11.11, electerm uses remote-supplied filenames directly with path.join() while receiving Zmodem and Trzsz transfers. In src/app/server/zmodem.js, prepareReceiveFile() joins the filename to the user-selected save path, and in src/app/server/trzsz.js, getUniqueFilePath(), the openSaveFile() callback, and the savedFilePaths mapping construct destinations without sanitization. A malicious SSH server or remote shell can provide a filename containing traversal components such as ../escaped.txt or ../../.bashrc. When the victim accepts the transfer and selects a download directory, electerm can write outside that directory and overwrite files accessible to the desktop user, potentially changing sensitive configuration or impairing availability. This issue is fixed in version 3.11.11.
Affected versions and mitigation
From the CVE record and the vendor's references.Affected
- < 3.11.11
Fixed in 3.11.11
Mitigation
Upgrade electerm to 3.11.11 or later.
References
- Vendor advisory github.com/electerm/electerm/security/advisori…
- Patch github.com/electerm/electerm/commit/fde153d677…
- Release notes github.com/electerm/electerm/releases/tag/v3.1…
Timeline
Days relative to CVE publicationNo public PoC found yet; not in CISA KEV.
PoC repositories
Found on GitHub.No PoC repositories found yet.