SSH trust and local discovery

Finding an open SSH port is convenient, but it is not trust. Connection identity and credentials stay behind explicit user decisions.

Source baseline: app 1.0.1 (2) · 14 August 2026

Target discovery

Direct host and port entry is always available. When Wi-Fi is active, a separate discovery controller scans the current /24 for the selected TCP port and updates when either the port or Android's default network changes.

ImplementationFlutter UI with a Dart SSH client and terminal emulator
Automatic search254 addresses in the current Wi-Fi /24, selected TCP port only
AuthenticationUsername and password
Server identityTOFU host-key fingerprint per host and port

Discovery produces candidate endpoints; it never starts a session by itself. This keeps availability probing separate from authentication and authorization.

WiFi Scanner can open dstools-ssh://connect/connect?host=<host>&port=<port>. Only host and port cross that app boundary. Username, password, commands, and terminal text are deliberately excluded.

TOFU and secure local storage

On first connection, the app displays the server key type and SHA-256 fingerprint for approval. The accepted fingerprint is stored for that target. A later mismatch produces a changed-key warning rather than silently replacing the known value.

TOFU detects change after first trust. It does not prove that the first endpoint was legitimate; users should compare the first fingerprint through a separate trusted channel when that matters.

Saved credentials and known-host fingerprints use Android-backed secure storage through the app's secure key-value boundary. They remain local unless the user deletes app data or removes an entry.

Terminal data path

After authentication, the client opens a PTY sized from the terminal view. Standard output and error are decoded and streamed into the terminal; terminal input is encoded and written back to the SSH session. Resize events update the remote PTY, while a mobile key bar supplies keys that are awkward on a soft keyboard.

Verification and known limits

Tests cover Wi-Fi network changes, port scanning, discovery cancellation, target parsing, secure-store behavior, TOFU decisions, terminal key translation, settings, and localized UI paths.