Using Windows's new native OpenSSH ssh.exe thg hangs forever (host verification step the first time is interactive)
Created originally on Bitbucket by joonas_fi (Joonas Loppi)
Nowadays Windows has native OpenSSH built-in: https://docs.microsoft.com/en-us/windows-server/administration/openssh/openssh_install_firstuse
I think it’s good to migrate to it, because now it works around the same in Linux and Windows and Putty’s SSH agent protocol implementation (pageant) is very hacky.
Now that on Windows OpenSSH handles the SSH agent as well, I think the protocol is about the same as in Linux (though on Windows it uses named pipe (name: `openssh-ssh-agent`) probably because Unix sockets are not yet generally available on Windows).
What didn’t work:
TortoiseHg just hanged forever when I tried to push to GitHub (I use hggit). Observing the command line (`ssh git@github.com "git-receive-pack 'function61/turbobob.git'"`) I did the same from command prompt, and ssh.exe asked me to accept GitHub’s host RSA key fingerprint. The `git-receive-pack` command did its thing successfully.
Now that the host key ack is stored, OpenSSH + Git integration works from TortoiseHg flawlessly.
tl;dr: we may need to pass a flag to ssh.exe for it to accept host key automatically (if seeing that host’s key for the first time) and to make SSH command automatically fail if host key verification fails?