mirror of
https://github.com/binaricat/Netcatty.git
synced 2026-11-24 17:32:18 +00:00
Addresses two correctness issues from the codex review of the ET protocol support. codex P1 #1 (Unix askpass helper): on macOS/Linux the SSH_ASKPASS helper was the askpass .cjs itself, relying on its `#!/usr/bin/env node` shebang. Packaged Electron builds put no `node` on the user's PATH, so ssh could not run the helper and ET could not supply the saved password / key passphrase, failing the connection outright. Mirror the existing Windows .cmd wrapper: write a small /bin/sh wrapper that execs the helper through process.execPath with ELECTRON_RUN_AS_NODE=1 (process.execPath is POSIX single-quoted to survive spaces in an .app path). codex P1 #2 (jump host routing): a jumped ET host only got an ssh ProxyCommand, which fixes the SSH bootstrap but leaves ET opening its TCP socket straight at the destination etserver — which fails whenever the destination ET port is not directly reachable. Use ET's own --jumphost/--jport so ET connects its socket to the jumphost's etserver and reaches the destination over the SSH tunnel ET sets up (`ssh -J`). Per-hop jump credentials move from the ProxyCommand into a `Host <jumphost>` ssh_config block (OpenSSH applies command-line -o only to the final hop, so jump settings must come from config); the destination's comma/space options are scoped under a `Host <dest>` block with a ProxyJump so the standalone ssh used for distro detection tunnels through the jump too. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>