Repository Analysis

electerm/electerm

📻Terminal/ssh/sftp/ftp/telnet/serialport/RDP/VNC/Spice client(linux, mac, win)

3.4 Likely human-written View on GitHub
3.4
Adjusted Score
3.4
Raw Score
100%
Time Factor
2026-05-30
Last Push
14,185
Stars
JavaScript
Language
103,731
Lines of Code
700
Files
152
Pattern Hits
2026-05-31
Scan Date

Score History

Severity Breakdown

CRITICAL 0HIGH 0MEDIUM 81LOW 71

Pattern Findings

152 matches across 5 categories. Click a row to expand file-level details.

Decorative Section Separators81 hits · 258 pts
SeverityFileLineSnippet
MEDIUMtest/unit/mcp-widget.spec.js17// ── Electron mock ─────────────────────────────────────────────────────────────
MEDIUMtest/unit/mcp-widget.spec.js29// ── Mock renderer (win) ───────────────────────────────────────────────────────
MEDIUMtest/unit/mcp-widget.spec.js48// ── Intercept require() before loading the widget ─────────────────────────────
MEDIUMtest/unit/mcp-widget.spec.js64// ── SSE helper (mirrors mcp.spec.js) ─────────────────────────────────────────
MEDIUMtest/unit/mcp-widget.spec.js101// ─────────────────────────────────────────────────────────────────────────────
MEDIUMtest/unit/mcp-widget.spec.js103// ─────────────────────────────────────────────────────────────────────────────
MEDIUMtest/unit/mcp-widget.spec.js136// ─────────────────────────────────────────────────────────────────────────────
MEDIUMtest/unit/mcp-widget.spec.js138// ─────────────────────────────────────────────────────────────────────────────
MEDIUMtest/unit/mcp-widget.spec.js183// ─────────────────────────────────────────────────────────────────────────────
MEDIUMtest/unit/mcp-widget.spec.js185// ─────────────────────────────────────────────────────────────────────────────
MEDIUMtest/unit/mcp-widget.spec.js216// ─────────────────────────────────────────────────────────────────────────────
MEDIUMtest/unit/mcp-widget.spec.js218// ─────────────────────────────────────────────────────────────────────────────
MEDIUMtest/unit/mcp-widget.spec.js262// ─────────────────────────────────────────────────────────────────────────────
MEDIUMtest/unit/mcp-widget.spec.js264// ─────────────────────────────────────────────────────────────────────────────
MEDIUMtest/unit/mcp-widget.spec.js346// ─────────────────────────────────────────────────────────────────────────────
MEDIUMtest/unit/mcp-widget.spec.js348// ─────────────────────────────────────────────────────────────────────────────
MEDIUMtest/unit/mcp-widget.spec.js415// ─────────────────────────────────────────────────────────────────────────────
MEDIUMtest/unit/mcp-widget.spec.js417// ─────────────────────────────────────────────────────────────────────────────
MEDIUMtest/unit/mcp.spec.js101 // ─── Protocol-level tests (no renderer needed) ──────────────────────────
MEDIUMtest/unit/mcp.spec.js196 // ─── Tool call protocol tests ───────────────────────────────────────────
MEDIUMtest/unit/mcp.spec.js232 // ─── Renderer-dependent terminal tests ──────────────────────────────────
MEDIUMtest/unit/mcp.spec.js412 // ─── Direct tab open tests ─────────────────────────────────────────────
MEDIUMtest/unit/mcp.spec.js521 // ─── onData test ────────────────────────────────────────────────────────
MEDIUMtest/unit/mcp.spec.js538 // ─── Terminal idle tests ────────────────────────────────────────────────
MEDIUMtest/unit-ci/session-ssh-agent.spec.js39// ─── constants ────────────────────────────────────────────────────────────────
MEDIUMtest/unit-ci/session-ssh-agent.spec.js48// ─── helpers ──────────────────────────────────────────────────────────────────
MEDIUMtest/unit-ci/session-ssh-agent.spec.js227// ─── fixture management ────────────────────────────────────────────────────────
MEDIUMtest/unit-ci/session-ssh-agent.spec.js265 // ── test 1 ─────────────────────────────────────────────────────────────────
MEDIUMtest/unit-ci/session-ssh-agent.spec.js327 // ── test 2 ─────────────────────────────────────────────────────────────────
MEDIUMtest/unit-ci/session-ssh-agent.spec.js377 // ── test 3 ─────────────────────────────────────────────────────────────────
MEDIUMtest/unit-ci/session-ssh-agent.spec.js424 // ── test 4 ─────────────────────────────────────────────────────────────────
MEDIUMtest/e2e/023.batch-op.spec.js25// ─── helpers ──────────────────────────────────────────────────────────────────
MEDIUMtest/e2e/023.batch-op.spec.js61// ─── tests ────────────────────────────────────────────────────────────────────
MEDIUMtest/e2e/023.batch-op.spec.js73 // ── open widgets panel ─────────────────────────────────────────────────
MEDIUMtest/e2e/023.batch-op.spec.js77 // ── click the Batch Operation widget ──────────────────────────────────
MEDIUMtest/e2e/023.batch-op.spec.js89 // ── Load Template and verify editor populated ──────────────────────────
MEDIUMtest/e2e/023.batch-op.spec.js99 // ── set the full example workflow (connect + commands + sftp) ──────────
MEDIUMtest/e2e/023.batch-op.spec.js103 // ── execute workflow ───────────────────────────────────────────────────
MEDIUMtest/e2e/021.cmd-history.spec.js23// ─── helpers ──────────────────────────────────────────────────────────────────
MEDIUMtest/e2e/021.cmd-history.spec.js92// ─── test ─────────────────────────────────────────────────────────────────────
MEDIUMtest/e2e/021.cmd-history.spec.js96 // ── first session ──────────────────────────────────────────────────────────
MEDIUMtest/e2e/021.cmd-history.spec.js112 // ── step 1: run cmd1 in terminal → should appear in history ───────────────
MEDIUMtest/e2e/021.cmd-history.spec.js127 // ── step 2: click the item to re-run the command ──────────────────────────
MEDIUMtest/e2e/021.cmd-history.spec.js147 // ── step 3: delete the item ────────────────────────────────────────────────
MEDIUMtest/e2e/021.cmd-history.spec.js157 // ── step 4: run cmd2 that should persist after restart ────────────────────
MEDIUMtest/e2e/021.cmd-history.spec.js165 // ── second session (restart) ───────────────────────────────────────────────
MEDIUMtest/e2e/020.trzsz-rzsz.spec.js34// ─── helpers ──────────────────────────────────────────────────────────────────
MEDIUMtest/e2e/020.trzsz-rzsz.spec.js81// ─── transfer helpers ─────────────────────────────────────────────────────────
MEDIUMtest/e2e/020.trzsz-rzsz.spec.js133// ─── test ─────────────────────────────────────────────────────────────────────
MEDIUMtest/e2e/020.trzsz-rzsz.spec.js164 // ── trz ────────────────────────────────────────────────────────────────────
MEDIUMtest/e2e/020.trzsz-rzsz.spec.js168 // ── tsz ────────────────────────────────────────────────────────────────────
MEDIUMtest/e2e/020.trzsz-rzsz.spec.js180 // ── rz ────────────────────────────────────────────────────────────────────
MEDIUMtest/e2e/020.trzsz-rzsz.spec.js186 // ── sz ────────────────────────────────────────────────────────────────────
MEDIUMtest/e2e/022.session-history.spec.js25// ─── helpers ──────────────────────────────────────────────────────────────────
MEDIUMtest/e2e/022.session-history.spec.js59// ─── test ─────────────────────────────────────────────────────────────────────
MEDIUMtest/e2e/022.session-history.spec.js63 // ── first session ──────────────────────────────────────────────────────────
MEDIUMtest/e2e/022.session-history.spec.js80 // ── step 1: open SSH session → history entry created ──────────────────────
MEDIUMtest/e2e/022.session-history.spec.js101 // ── step 2: open sidebar history → item visible ────────────────────────────
MEDIUMtest/e2e/022.session-history.spec.js107 // ── step 3: click history item → new tab opens ────────────────────────────
MEDIUMtest/e2e/022.session-history.spec.js115 // ── step 4: bookmark icon → creates a bookmark ────────────────────────────
21 more matches not shown…
Verbosity Indicators34 hits · 55 pts
SeverityFileLineSnippet
LOWtest/unit/mcp2.spec.js314 // Step 1: Create SSH bookmark
LOWtest/unit/mcp2.spec.js328 // Step 2: Open the bookmark
LOWtest/unit/mcp2.spec.js335 // Step 3: List /tmp directory
LOWtest/unit/mcp2.spec.js346 // Step 4: Stat /tmp
LOWtest/unit/mcp2.spec.js356 // Step 5: Read /etc/hostname
LOWtest/unit/mcp2.spec.js366 // Step 6: Clean up - delete test bookmark
LOWtest/unit/mcp.spec.js237 // Step 1: Open a local terminal
LOWtest/unit/mcp.spec.js247 // Step 2: Send a command
LOWtest/unit/mcp.spec.js261 // Step 3: Get terminal output and verify command was executed
LOWtest/unit/mcp.spec.js301 // Step 1: Create SSH bookmark
LOWtest/unit/mcp.spec.js316 // Step 2: Open/connect to the bookmark
LOWtest/unit/mcp.spec.js327 // Step 3: Send a command with retry
LOWtest/unit/mcp.spec.js351 // Step 4: Get terminal output and verify command was executed
LOWtest/unit/mcp.spec.js364 // Step 5: Clean up - delete the test bookmark
LOWtest/unit/mcp.spec.js373 // Step 6: Verify the bookmark was actually deleted
LOWtest/unit/mcp.spec.js427 // Step 1: Open SSH tab directly (no bookmark created)
LOWtest/unit/mcp.spec.js445 // Step 2: Send a command with retry
LOWtest/unit/mcp.spec.js469 // Step 3: Get terminal output and verify command was executed
LOWtest/unit/mcp.spec.js481 // Step 4: Verify no bookmark was created for this connection
LOWtest/unit/mcp.spec.js488 // Step 5: Close the tab
LOWnpm/install.js303 // Step 1: Mount the DMG
LOWnpm/install.js321 // Step 2: Find the .app bundle
LOWnpm/install.js343 // Step 3: Copy the app to /Applications
LOWnpm/install.js346 // Step 4: Detach the DMG (always, regardless of copy result)
LOWsrc/app/server/rdp-proxy.js379 // Step 1: TCP connect (direct or through proxy)
LOWsrc/app/server/rdp-proxy.js401 // Step 3: Read X.224 Connection Confirm
LOWsrc/app/server/rdp-proxy.js415 // Step 4: TLS handshake via node-forge (pure JS — no BoringSSL)
LOWsrc/app/server/rdp-proxy.js435 // Step 5: Convert captured certificates to DER
LOWsrc/app/server/rdp-proxy.js617 // Step 1: Parse RDCleanPath request
LOWsrc/app/server/rdp-proxy.js621 // Step 2: Parse destination
LOWsrc/app/server/rdp-proxy.js633 // Step 6: Build and send RDCleanPath response
LOWsrc/app/server/rdp-proxy.js641 // Step 7: Bidirectional relay via node-forge
LOWsrc/client/components/file-transfer/transfer.jsx707 // Step 1: Create all folders concurrently in batches
LOWsrc/client/components/file-transfer/transfer.jsx731 // Step 2: Process contents of each folder sequentially
Hyper-Verbose Identifiers20 hits · 20 pts
SeverityFileLineSnippet
LOWtest/unit-ci/session-ssh.spec.js184function sameRoundKeyboardInteractiveAuth () {
LOWtest/unit-ci/session-ssh.spec.js205function splitRoundKeyboardInteractiveAuth (rounds = []) {
LOWtest/e2e/019.drag-folder.spec.js166async function ensureItemVisibleAtCurrentOrParent (client, type, itemName, maxHops = 8) {
LOWtest/e2e/009.8.file-op-with-keyboard.spec.js38async function testCopyPasteOperationWithKeyboard (client, type) {
LOWtest/e2e/common/common.js241async function confirmSshHostKeyVerificationIfNeeded (client, timeout = 4000) {
LOWtest/e2e/common/common.js405async function verifyFileTransfersComplete (client) {
LOWsrc/app/server/sftp-file.js7function createReadStreamFromString (str) {
LOWsrc/app/server/session-api.js38async function toggleTerminalLogTimestamp (body) {
LOWsrc/app/server/terminal-api.js44function toggleTerminalLogTimestamp (ws, msg) {
LOWsrc/app/lib/deep-link.js62function checkProtocolRegistration () {
LOWsrc/client/components/terminal/shell.js107export function getInlineShellIntegration (shellType) {
LOWsrc/client/components/terminal/shell.js141export function getShellIntegrationCommand (shellType = 'bash') {
LOWsrc/client/components/terminal/terminal-apis.js38export function toggleTerminalLogTimestamp (pid) {
LOW…/client/components/bookmark-form/common/init-values.js68export function getTerminalBackgroundDefaults (defaultSetting) {
LOW…/components/common/connection-hopping-warning-text.jsx13export default function ConnectionHoppingWarningText (props) {
LOWsrc/client/components/theme/theme-list-item.jsx51 function handleTooltipVisibleChange (visible) {
LOWsrc/client/components/ai/agent-tools.js4function buildAddBookmarkParameters () {
LOWsrc/client/components/ai/agent.js35async function callBackendAIchatWithTools (messages, config) {
LOWsrc/client/components/shortcuts/shortcut-handler.js43export function handleTerminalSelectionReplace (event, ctx) {
LOWsrc/client/store/sync.js37function updateSyncServerStatusFromGist (store, gist, type) {
Over-Commented Block16 hits · 16 pts
SeverityFileLineSnippet
LOWtest/e2e/018.file-transfer-conflict.spec.js201 // Count and return the number of selected items
LOW.github/workflows/linux-loong64-legacy.yml1# Build electerm for loong64 (LoongArch64) Linux - Legacy (old world)
LOWsrc/app/server/session-sftp.js201 */
LOWsrc/app/server/session-sftp.js241 return this.buildRemoteCommand('rmrf', remotePath)
LOWsrc/app/server/download-upgrade.js61 proxy,
LOWsrc/app/lib/on-close.js41 // }, {
LOWsrc/app/widgets/widget-local-file-server.js61 },
LOWsrc/app/widgets/load-widget.js41 return res
LOWsrc/client/components/tabs/tab.jsx81 clearPasswordPrompt = () => {
LOWsrc/client/components/web/web-session.jsx81 // if (webview) {
LOWsrc/client/common/download.jsx1/**
LOWsrc/client/store/sync.js121 // }
LOWsrc/client/store/sync.js521 // const status = JSON.parse(gist.files['electerm-status.json'].content)
LOWsrc/client/store/mcp-handler.js301 }
LOWsrc/client/store/mcp-handler.js321
LOWsrc/client/store/mcp-handler.js341 // }
Overly Generic Function Names1 hit · 1 pts
SeverityFileLineSnippet
LOWsrc/client/common/db.js148export async function getData (name) {