Commit Graph

5 Commits

Author SHA1 Message Date
Vantz Stockwell
bce77e0932 feat: wire SFTP CWD following — listen for OSC 7 events + inject shell hook
All checks were successful
Build & Sign Wraith / Build Windows + Sign (push) Successful in 1m2s
Two missing halves of CWD tracking:

1. Frontend: useSftp now listens for ssh:cwd:{sessionId} Wails events
   and calls navigateTo() when followTerminal is enabled (default: on).

2. Backend: re-added shell integration injection with stty -echo to
   suppress visible command output. Leading space keeps it out of
   shell history. Handles both bash (PROMPT_COMMAND) and zsh (precmd).

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-17 14:00:24 -04:00
Vantz Stockwell
c31563c8c6 fix: remove shell integration injection — echoes visibly in terminal
All checks were successful
Build & Sign Wraith / Build Windows + Sign (push) Successful in 1m1s
The CWD tracking PROMPT_COMMAND/precmd injection wrote raw escape
sequences to stdin that echoed back to the user. Removed until we
have a non-echoing mechanism (e.g., second SSH channel or .bashrc
modification). CWD tracking still works passively for shells that
already emit OSC 7 sequences.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-17 13:50:10 -04:00
Vantz Stockwell
6729eb5b80 feat: wire 4 backend services — host key verification, CWD tracking, session manager, workspace restore
U-1: Replace ssh.InsecureIgnoreHostKey() with TOFU (Trust On First Use) host
key verification via HostKeyStore. New keys auto-store, matching keys accept
silently, CHANGED keys reject with MITM warning. Added DeleteHostKey() for
legitimate re-key scenarios.

U-2: Wire CWDTracker per SSH session. readLoop() now processes OSC 7 escape
sequences, strips them from terminal output, and emits ssh:cwd:{sessionID}
Wails events on directory changes. Shell integration commands (bash/zsh
PROMPT_COMMAND) injected after connection.

U-3: Session manager now tracks all SSH and RDP sessions via CreateWithID()
which accepts the service-level UUID instead of generating a new one.
ConnectSSH, ConnectSSHWithPassword, ConnectRDP register sessions;
DisconnectSession and RDPDisconnect remove them. ConnectedAt timestamp set.

U-4: WorkspaceService instantiated in New(), clean shutdown flag managed on
startup/exit, workspace state auto-saved on every session open/close.
Frontend-facing proxy methods exposed: SaveWorkspace, LoadWorkspace,
MarkCleanShutdown, WasCleanShutdown, GetSessionCWD.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-17 13:41:58 -04:00
Vantz Stockwell
05776b7eb6 fix: streaming UTF-8 decoder + rAF write batching for terminal performance
All checks were successful
Build & Sign Wraith / Build Windows + Sign (push) Successful in 1m6s
Three fixes:

1. Streaming TextDecoder: a single TextDecoder instance with {stream: true}
   persists across events. Split multi-byte UTF-8 sequences at Go read()
   boundaries are now buffered and decoded correctly across chunks.

2. requestAnimationFrame batching: incoming SSH data is accumulated and
   flushed to xterm.js once per frame instead of on every Wails event.
   Eliminates the laggy typewriter effect when output arrives in small
   chunks (which is normal for SSH PTY output).

3. PTY baud rate: bumped TTY_OP_ISPEED/OSPEED from 14400 (modem speed)
   to 115200. Some remote PTYs throttle output to match the declared rate.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-17 13:22:50 -04:00
Vantz Stockwell
8a096d7f7b Wraith v0.1.0 — Desktop SSH + RDP + SFTP Client
Some checks failed
Build & Sign Wraith / Build Windows + Sign (push) Has been cancelled
Go + Wails v3 + Vue 3 + SQLite + FreeRDP3 (purego)
183 tests, 76 source files, 9,910 lines of code

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-17 08:19:29 -04:00