Git via SSH from Windows, Permission Denied

I’m trying to setup my Windows 10 environment to pull down my repositories over SSH. I’ve followed all the instructions on Github to generate, add, and upload the public key to Github. I’ve verified that Github allows me to connect using the following command:

> ssh -T git@github.com
Hi parithon! You've successfully authenticated, but Github does not provide shell access.

However, when I try to clone any of my repositories I always receive a permission denied error.

> git clone git@github.com:parithon/CoreWiki.git
Cloning inti 'CorWiki'...
git@github.com: Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

So I re-verified my public key is working:

> ssh -vT git@github.com
OpenSSH_for_Windows_7.6p1, LibreSSL 2.6.4
debug1: Connecting to github.com [192.30.255.112] port 22.
debug1: Connection established.
debug1: key_load_public: No such file or directory
debug1: identity file C:\\Users\\.../.ssh/id_rsa type -1
debug1: key_load_public: No such file or directory
debug1: identity file C:\\Users\\.../.ssh/id_rsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file C:\\Users\\.../.ssh/id_dsa type -1
debug1: key_load_public: No such file or directory
debug1: identity file C:\\Users\\.../.ssh/id_dsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file C:\\Users\\.../.ssh/id_ecdsa type -1
debug1: key_load_public: No such file or directory
debug1: identity file C:\\Users\\.../.ssh/id_ecdsa-cert type -1
debug1: key_load_public: No such file or directory
debug1: identity file C:\\Users\\.../.ssh/id_ed25519 type -1
debug1: key_load_public: No such file or directory
debug1: identity file C:\\Users\\.../.ssh/id_ed25519-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_for_Windows_7.6
debug1: Remote protocol version 2.0, remote software version libssh_0.7.0
debug1: no match: libssh_0.7.0
debug1: Authenticating to github.com:22 as 'git'
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug1: kex: algorithm: curve25519-sha256@libssh.org
debug1: kex: host key algorithm: ssh-rsa
debug1: kex: server->client cipher: chacha20-poly1305@openssh.com MAC: <implicit> compression: none
debug1: kex: client->server cipher: chacha20-poly1305@openssh.com MAC: <implicit> compression: none
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: Server host key: ssh-rsa SHA256:...
debug1: Host 'github.com' is known and matches the RSA host key.
debug1: Found key in C:\\Users\\.../.ssh/known_hosts:1
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug1: rekey after 134217728 blocks
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey
debug1: Next authentication method: publickey
debug1: Offering public key: RSA SHA256:... .\\id_rsa_github
debug1: Server accepts key: pkalg ssh-rsa blen 535
debug1: Authentication succeeded (publickey).
Authenticated to github.com ([192.30.255.112]:22).
debug1: channel 0: new [client-session]
debug1: Entering interactive session.
debug1: pledge: network
debug1: client_input_channel_req: channel 0 rtype exit-status reply 0
Hi parithon! You've successfully authenticated, but GitHub does not provide shell access.
debug1: channel 0: free: client-session, nchannels 1 Transferred: sent 3224, received 2024 bytes, in 0.6 seconds

Yet, cloning doesn’t work.

Has anybody seen this issue? Am I doing something wrong?

Hi @parithon,

Thanks for being part of the GitHub Community Forum. It looks like you’ve opened this same topic in multiple places. You have a similar post already: https://github.community/t5/How-to-use-Git-and-GitHub/Git-via-SSH-from-Windows-returns-Permission-Denied/m-p/9336.

For this reason, I will be locking this thread. You can continue the conversation in your original post. We do ask that you no longer cross-post in the Community Forum. If you’re ever concerned that your post hasn’t shown up right after you made it, we recommend waiting at least an hour in order to avoid accidental duplicate posts. Sometimes posts get caught in a moderation queue, but our team reviews them as quickly as possible.

For additional guidance, please review our Community Forum Code of Conduct.

Cheers!