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.
| Implementation | Flutter UI with a Dart SSH client and terminal emulator |
|---|---|
| Automatic search | 254 addresses in the current Wi-Fi /24, selected TCP port only |
| Authentication | Username and password |
| Server identity | TOFU 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.
Deep-link boundary
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.
- The target is parsed and validated before the credential prompt appears.
- A deep link skips broad discovery because the caller has already chosen an endpoint.
- Stored credentials may prefill locally, but they are not part of the link.
- Separate Android sandboxes mean credentials from another app are not silently imported.
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.
- Connection work is scoped to the terminal page lifecycle.
- Closing the page closes the session instead of leaving a hidden shell.
- The terminal displays a local end marker when the stream closes.
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.
- Automatic discovery is IPv4 /24 convenience, not a general network inventory.
- Firewalls and client isolation can hide a reachable SSH server.
- The current product path documents password authentication; key-file workflows are not implied.
- The user remains responsible for authorization to access the selected host.