fix(ssh): confirm changed host identities - #297
Open
DatScreamer wants to merge 3 commits into
Open
Conversation
DatScreamer
marked this pull request as draft
August 14, 2026 13:26
russh reports a rejected host key as UnknownKey from client::connect, but the code only checked the rejected-fingerprint flag after a successful connect, so the typed HostKeyVerification error (and the host-key-changed marker) never fired in any flow. Check the rejected fingerprint on the connect-error path too. Also wire the trust-store pin policy into the flows that still accepted every key: the guided SSH connect, ssh_connect_and_bootstrap, ssh_open_session, and the SSH bridge reconnect plan. Pin on first connect and reject changed host identities. iOS: route host-key-changed during guided connect to the confirm modal instead of a hard Connection Failed dialog, and add keychain-access-groups to the Debug entitlements so the simulator Keychain (trust store) works.
DatScreamer
marked this pull request as ready for review
August 15, 2026 01:05
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Protect saved-server and terminal SSH reconnects from silently accepting a changed host identity.
Changes
Verification
git diff --checkpasses.Closes #296