Re: Question about ssh fingerprint
Wouldn't a man in the middle attack be possible if the attacker knew the SSH fingerprint? Couldn't he use the same SSH fingerprint on his machine to fool you into thinking his is the right server?
Sure he can, but WinSCP then encrypts the data it sends (including your credentials) using that public key. The attacker would not be able to decrypt these as he/she does not know a private key.
For the same reason, anyone can learn a public key of the server using hostname only, as the server needs to announce the public key to a client, even before the client authenticates. That's the point of the key being "public".