Version of Libgit2 on Windows different from from Linux?

We have some issues accessing packages hosted on private repos at GitHub. Long story short, using v1.8.3 on windows and ssh-agent with the appropriate key added to known_hosts, and get the error:

SSH host verification: the identity of the server `` does not match its known hosts record. Someone could be trying to man-in-the-middle your connection. It is also possible that the server has changed its key, in which case you should check with the server administrator and if they confirm that the key has been changed, update your known hosts file.

(steps to reproduce is to add a private repo at GitHub in Pkg)

A workaround is to use the git client by setting


but that is quite annoying, and garbles the status prints.

On Linux on the other hand (also v1.8.3), adding the private repo works without issues. Does this mean that the windows release uses a different version of libgit2? Or what else could be going on here?

I just noticed this myself, on 1.8.3 and an M1 mac with a private repo. The github host key is correct in my known_hosts and I can ssh -T just fine. The env setting above also fixes the problem.

[edit] More info at known_hosts SSH verification failing for · Issue #40297 · JuliaLang/julia · GitHub