Errors

85 views
Skip to first unread message

Wei Hu

unread,
Sep 13, 2023, 8:32:29 AM9/13/23
to git-for-windows
Can't read form repo.
Always show `Permission denied (publickey)`
I try reinstall the git , and regenerate ssh-key and add to the github ssh-key .
But it's not work for my machine.
I can't clone repo from github and can't also push to github.

Konstantin Khomoutov

unread,
Sep 13, 2023, 10:35:34 AM9/13/23
to git-for...@googlegroups.com
The usual approach to debug such issues is as follows.

First, run any of the failing commands in a console window while having

GIT_TRACE=1

in the environment.
(Exactly how to do that depends on your shell of choice.)

This setting makes Git verbosely pring which external programs it calls.
verify that output lists an invocation of "ssh" and take a note of its full
pathname, if any.

The, re-run the command while having

GIT_SSH_COMMAND="ssh -vvv"

in the environment. Replace "ssh" in my example with its full pathname, if the
previous command displayed a full pathname, rather than plain "ssh".
This setting makes Git pass the ssh program it invokes a couple of "be
verbose" command-line flags (each one makes the output ever more verbose).

Study what ssh prints, and try to figure out whether it reads your private key
file. If it doesn't, it has to print how it asked for keys from an SSH key
agent which is supposed to be running. Debugging _this_ might be a bit more
complicated, but let's start small.

To reiterate, the code idea of such debugging is to verify SSH actually reads
and tries to use the private key, the public part of which you've reportedly
registered at Github.

Konstantin Khomoutov

unread,
Sep 13, 2023, 10:39:37 AM9/13/23
to git-for...@googlegroups.com
On Wed, Sep 13, 2023 at 05:35:30PM +0300, Konstantin Khomoutov wrote:

[...]
> The, re-run the command while having
>
> GIT_SSH_COMMAND="ssh -vvv"
>
> in the environment.
[...]
> To reiterate, the code idea of such debugging is to verify SSH actually reads
> and tries to use the private key, the public part of which you've reportedly
> registered at Github.

To demonstrate, on my system I get something like

debug1: Offering public key: /home/kostix/.ssh/blah ED25519 SHA256:Szi...
debug3: send packet: type 50
debug2: we sent a publickey packet, wait for reply
debug3: receive packet: type 60
debug1: Server accepts key: /home/kostix/.ssh/blah ED25519 SHA256:Szi...

Which lists how SSH offered a particular key to the server, waited for its
reply, and the sever said it accepted that key.

The output also means that level 2 debugging (using just two -v, as in
"ssh -vv") should be enough.

Wei Hu

unread,
Sep 13, 2023, 12:47:03 PM9/13/23
to git-for-windows
Thank you for your forgiveness . This is my first time to use Groups . I feel so sorry to reply you in private.
I try the command `$env:GIT_TRACE=1` and I try the command `git fetch` under my local-repo , here the log result :
git fetch
00:43:22.784853 exec-cmd.c:244          trace: resolved executable dir: C:/Program Files/Git/mingw64/bin
00:43:22.805636 git.c:463               trace: built-in: git fetch
00:43:22.807638 run-command.c:659       trace: run_command: git fsmonitor--daemon start
00:43:22.966279 exec-cmd.c:244          trace: resolved executable dir: C:/Program Files/Git/mingw64/libexec/git-core
00:43:22.966279 git.c:463               trace: built-in: git fsmonitor--daemon start
00:43:22.973796 run-command.c:659       trace: run_command: git fsmonitor--daemon run --detach --ipc-threads=8
00:43:22.991703 run-command.c:659       trace: run_command: unset GIT_PREFIX; GIT_PROTOCOL=version=2 ssh -o SendEnv=GIT_PROTOCOL g...@github.com 'git-upload-pack '\''PreX-AW/Obsidian.git'\'''
g...@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.

Konstantin Khomoutov

unread,
Sep 13, 2023, 12:56:47 PM9/13/23
to git-for...@googlegroups.com
On Wed, Sep 13, 2023 at 09:47:03AM -0700, Wei Hu wrote:

[...]
> I try the command `$env:GIT_TRACE=1` and I try the command `git fetch`
> under my local-repo , here the log result :
[...]
> 00:43:22.991703 run-command.c:659 trace: run_command: unset
> GIT_PREFIX; GIT_PROTOCOL=version=2 ssh -o SendEnv=GIT_PROTOCOL
[...]

So, there it is: Git calls SSH just as "ssh".

Now let's move on to what I suggested in my original reply:

>>> The, re-run the command while having
>>>
>>> GIT_SSH_COMMAND="ssh -vvv"
>>>
>>> in the environment.

Looks like two -v will suffice, so you might set

$env:GIT_SSH_COMMAND="ssh -vv"

and try fetching again. Looks for messages which involve offering keys and
what the server said about them. Is the key you have generated for use with
Github listed in the output (was it offered)? If yes, what Github responded to
your SSH client back?

Wei Hu

unread,
Sep 13, 2023, 1:09:48 PM9/13/23
to git-for-windows
The key I generated and add to Github SSH list seem don't appear in the log.
Besides , I try the $env:GIT_SSH_COMMAND="ssh -vvv" . But it's doesn't work.
$env:GIT_SSH_COMMADN="ssh -vv"
git fetch
01:03:54.428380 exec-cmd.c:244          trace: resolved executable dir: C:/Program Files/Git/mingw64/bin
01:03:54.428380 git.c:463               trace: built-in: git fetch
01:03:54.428380 run-command.c:659       trace: run_command: unset GIT_PREFIX; GIT_PROTOCOL=version=2 ssh -o SendEnv=GIT_PROTOCOL g...@github.com 'git-upload-pack '\''PreX-AW/Obsidian.git'\'''

g...@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.

Konstantin Khomoutov

unread,
Sep 13, 2023, 1:39:08 PM9/13/23
to git-for...@googlegroups.com
On Wed, Sep 13, 2023 at 10:09:48AM -0700, Wei Hu wrote:

> The key I generated and add to Github SSH list seem don't appear in the log.

This is because the SSH client is still not started in verbose mode due to
your mistyping the name of the variable - see below.

> Besides , I try the $env:GIT_SSH_COMMAND="ssh -vvv" . But it's doesn't work.
> $env:GIT_SSH_COMMADN="ssh -vv"

Because it should be GIT_SSH_COMMAND, not ...COMMADN ;-)

Wei Hu

unread,
Sep 13, 2023, 2:02:48 PM9/13/23
to git-for-windows
OKOK , I type the command correctly,and the PowerShell show a lot of debug log.

git fetch
01:56:05.143868 exec-cmd.c:244          trace: resolved executable dir: C:/Program Files/Git/mingw64/bin
01:56:05.153868 git.c:463               trace: built-in: git fetch
01:56:05.163866 run-command.c:659       trace: run_command: unset GIT_PREFIX; GIT_PROTOCOL=version=2 'ssh -vv' -o SendEnv=GIT_PROTOCOL g...@github.com 'git-upload-pack '\''PreX-AW/Obsidian.git'\'''
OpenSSH_9.4p1, OpenSSL 3.1.2 1 Aug 2023
debug1: Reading configuration data /etc/ssh/ssh_config
debug2: resolving "github.com" port 22
debug1: Connecting to github.com [20.205.243.166] port 22.
debug1: Connection established.
debug1: identity file /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_rsa type -1
debug1: identity file /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_rsa-cert type -1
debug1: identity file /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ecdsa type -1
debug1: identity file /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ecdsa-cert type -1
debug1: identity file /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ecdsa_sk type -1
debug1: identity file /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ecdsa_sk-cert type -1
debug1: identity file /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ed25519 type -1
debug1: identity file /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ed25519-cert type -1
debug1: identity file /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ed25519_sk type -1
debug1: identity file /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ed25519_sk-cert type -1
debug1: identity file /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_xmss type -1
debug1: identity file /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_xmss-cert type -1
debug1: identity file /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_dsa type -1
debug1: identity file /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_dsa-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_9.4
debug1: Remote protocol version 2.0, remote software version babeld-70f1bac9
debug1: compat_banner: no match: babeld-70f1bac9
debug2: fd 4 setting O_NONBLOCK
debug1: Authenticating to github.com:22 as 'git'
debug1: load_hostkeys: fopen /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/known_hosts2: No such file or directory
debug1: load_hostkeys: fopen /etc/ssh/ssh_known_hosts: No such file or directory
debug1: load_hostkeys: fopen /etc/ssh/ssh_known_hosts2: No such file or directory
debug1: SSH2_MSG_KEXINIT sent
debug1: SSH2_MSG_KEXINIT received
debug2: local client KEXINIT proposal
debug2: KEX algorithms: sntrup761x2...@openssh.com,curve25519-sha256,curve255...@libssh.org,ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group16-sha512,diffie-hellman-group18-sha512,diffie-hellman-group14-sha256,ext-info-c
debug2: host key algorithms: ssh-ed2551...@openssh.com,ecdsa-sha2-nis...@openssh.com,ecdsa-sha2-nis...@openssh.com,ecdsa-sha2-nis...@openssh.com,sk-ssh-ed25...@openssh.com,sk-ecdsa-sha2-n...@openssh.com,rsa-sha2-5...@openssh.com,rsa-sha2-2...@openssh.com,ssh-ed25519,ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521,sk-ssh-...@openssh.com,sk-ecdsa-sh...@openssh.com,rsa-sha2-512,rsa-sha2-256
debug2: ciphers ctos: chacha20...@openssh.com,aes128-ctr,aes192-ctr,aes256-ctr,aes12...@openssh.com,aes25...@openssh.com
debug2: ciphers stoc: chacha20...@openssh.com,aes128-ctr,aes192-ctr,aes256-ctr,aes12...@openssh.com,aes25...@openssh.com
debug2: MACs ctos: umac-...@openssh.com,umac-1...@openssh.com,hmac-sha...@openssh.com,hmac-sha...@openssh.com,hmac-s...@openssh.com,uma...@openssh.com,umac...@openssh.com,hmac-sha2-256,hmac-sha2-512,hmac-sha1
debug2: MACs stoc: umac-...@openssh.com,umac-1...@openssh.com,hmac-sha...@openssh.com,hmac-sha...@openssh.com,hmac-s...@openssh.com,uma...@openssh.com,umac...@openssh.com,hmac-sha2-256,hmac-sha2-512,hmac-sha1
debug2: compression ctos: none,zl...@openssh.com,zlib
debug2: compression stoc: none,zl...@openssh.com,zlib
debug2: languages ctos:
debug2: languages stoc:
debug2: first_kex_follows 0
debug2: reserved 0
debug2: peer server KEXINIT proposal
debug2: KEX algorithms: curve25519-sha256,curve255...@libssh.org,ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256
debug2: host key algorithms: ssh-ed25519,ecdsa-sha2-nistp256,rsa-sha2-512,rsa-sha2-256,ssh-rsa
debug2: ciphers ctos: chacha20...@openssh.com,aes25...@openssh.com,aes12...@openssh.com,aes256-ctr,aes192-ctr,aes128-ctr
debug2: ciphers stoc: chacha20...@openssh.com,aes25...@openssh.com,aes12...@openssh.com,aes256-ctr,aes192-ctr,aes128-ctr
debug2: MACs ctos: hmac-sha...@openssh.com,hmac-sha...@openssh.com,hmac-sha2-512,hmac-sha2-256
debug2: MACs stoc: hmac-sha...@openssh.com,hmac-sha...@openssh.com,hmac-sha2-512,hmac-sha2-256
debug2: compression ctos: none,zl...@openssh.com,zlib
debug2: compression stoc: none,zl...@openssh.com,zlib
debug2: languages ctos:
debug2: languages stoc:
debug2: first_kex_follows 0
debug2: reserved 0
debug1: kex: algorithm: curve25519-sha256
debug1: kex: host key algorithm: ssh-ed25519
debug1: kex: server->client cipher: chacha20...@openssh.com MAC: <implicit> compression: none
debug1: kex: client->server cipher: chacha20...@openssh.com MAC: <implicit> compression: none
debug1: expecting SSH2_MSG_KEX_ECDH_REPLY
debug1: SSH2_MSG_KEX_ECDH_REPLY received
debug1: Server host key: ssh-ed25519 SHA256:+DiY3wvvV6TuJJhbpZisF/zLDA0zPMSvHdkr4UvCOqU
debug1: load_hostkeys: fopen /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/known_hosts2: No such file or directory
debug1: load_hostkeys: fopen /etc/ssh/ssh_known_hosts: No such file or directory
debug1: load_hostkeys: fopen /etc/ssh/ssh_known_hosts2: No such file or directory
debug1: Host 'github.com' is known and matches the ED25519 host key.
debug1: Found key in /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/known_hosts:1
debug2: ssh_set_newkeys: mode 1
debug1: rekey out after 134217728 blocks
debug1: SSH2_MSG_NEWKEYS sent
debug1: expecting SSH2_MSG_NEWKEYS
debug1: SSH2_MSG_NEWKEYS received
debug2: ssh_set_newkeys: mode 0
debug1: rekey in after 134217728 blocks
debug1: Will attempt key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_rsa
debug1: Will attempt key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ecdsa

debug1: Will attempt key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ecdsa_sk
debug1: Will attempt key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ed25519
debug1: Will attempt key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ed25519_sk
debug1: Will attempt key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_xmss
debug1: Will attempt key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_dsa
debug2: pubkey_prepare: done
debug1: SSH2_MSG_EXT_INFO received
debug1: kex_input_ext_info: server-sig-algs=<ssh-ed2551...@openssh.com,ecdsa-sha2-nis...@openssh.com,ecdsa-sha2-nis...@openssh.com,ecdsa-sha2-nis...@openssh.com,sk-ssh-ed25...@openssh.com,sk-ecdsa-sha2-n...@openssh.com,rsa-sha2-5...@openssh.com,rsa-sha2-2...@openssh.com,ssh-rsa-...@openssh.com,sk-ssh-...@openssh.com,sk-ecdsa-sh...@openssh.com,ssh-ed25519,ecdsa-sha2-nistp521,ecdsa-sha2-nistp384,ecdsa-sha2-nistp256,rsa-sha2-512,rsa-sha2-256,ssh-rsa>
debug2: service_accept: ssh-userauth
debug1: SSH2_MSG_SERVICE_ACCEPT received
debug1: Authentications that can continue: publickey
debug1: Next authentication method: publickey
debug1: Trying private key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_rsa
debug1: Trying private key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ecdsa
debug1: Trying private key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ecdsa_sk
debug1: Trying private key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ed25519
debug1: Trying private key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ed25519_sk
debug1: Trying private key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_xmss
debug1: Trying private key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_dsa
debug2: we did not send a packet, disable method
debug1: No more authentication methods to try.

g...@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.

Konstantin Khomoutov

unread,
Sep 13, 2023, 2:14:59 PM9/13/23
to git-for...@googlegroups.com
On Wed, Sep 13, 2023 at 11:02:48AM -0700, Wei Hu wrote:

[...]
> debug1: Trying private key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_rsa
> debug1: Trying private key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ecdsa
> debug1: Trying private key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ecdsa_sk
> debug1: Trying private key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ed25519
> debug1: Trying private key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ed25519_sk
> debug1: Trying private key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_xmss
> debug1: Trying private key: /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_dsa
[...]

So, I repeat the question (for the third time, but well): which of these keys
is that you have generated to authenticate yourself at Github?

Please read carefully what I ask so I don't need to repeat myself - it wastes
time. If you have trouble understanding some questions - that is fine, but
then do not shy away and ask for clarifications.

Wei Hu

unread,
Sep 13, 2023, 2:24:26 PM9/13/23
to git-for-windows
I am so sorry .
But I added the id_rsa.pub to Github SSH list(Follow the tutorials from internet), not id_rsa.

Wei Hu

unread,
Sep 13, 2023, 2:36:31 PM9/13/23
to git-for-windows
Besides , the path of  id_rsa isn't correct , the path of id_rsa.pub(which I had add to Github) and id_rsa at another path. 

Konstantin Khomoutov

unread,
Sep 13, 2023, 3:07:33 PM9/13/23
to git-for-windows
On Wed, Sep 13, 2023 at 11:24:26AM -0700, Wei Hu wrote:

>> /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_rsa
>> /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ecdsa
>> /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ecdsa_sk
>> /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ed25519
>> /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_ed25519_sk
>> /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_xmss
>> /c/Users/PreX/AppData/Roaming/SPB_Data/.ssh/id_dsa
[...]

> But I added the id_rsa.pub to Github SSH list(Follow the tutorials from
> internet), not id_rsa.

This is correct: SSH (the `ssh-key` tool from OpenSSH, to be precise)
generates keys in the form of two files: one contains the private key (yours)
and another contains its public counterpart, and its name has an additional
suffix ".pub" to indicate its public (hence "pub").

> Besides , the path of id_rsa isn't correct , the path of id_rsa.pub(which
> I had add to Github) and id_rsa at another path.

Yay, we have finally arrived at the true cause of the problem, congrats ;-)

Well, exactly how to remedy the situation is up to you.
Possible solutions:

- The SSH client is able to use so-called "agent" to obtain the keys to
use - instead of reading the keys directly. If it's possible to make use
of this agent on Windows, I'd go this route (also see notes below).

- Replace id_rsa and id_rsa files at the path the SSH client called by Git
uses with the "correct" ones - which you have generated for Github.

I mean, these files at C:\Users\PreX\AppData\Roaming\SPB_Data\.ssh\

Be aware that if the keys located there are used to authenticate you
against some other SSH services, by overwriting these keys you will likely
lock yourself out of them, so think before you do!

- Make use of the fact the SSH client can be told to use a particular
key (which it calls "identity") via its "-i" command-line parameter.

With this approach you might make sure an appropriately crafted
GIT_SSH_COMMAND variable is seen by Git each time you're trying to work
with Github. For instance, it may read something like

ssh -i /c/some/path/to/your/github_rsa_key

- Figure out why the SSH client called by Git uses an "incorrect" -
in your opinion - location, and then try to figure out how to fix it.


Some notes.

Using Git on Windows (GfW) with SSH was complicated due to the fact Windows
for very long time did not ship any SSH implementation. Because of that GfW
has shipped a Windows port of OpenSSH with itself, and that one was used
by default. I have honestly no idea what's the situation now as I did not
use Windows for a long time. If this approach is still true, and you're
dealing with the SSH client shipped by GfW, then I could recomment
exploring an alternative setup which I was a happy user of. There exists a
fully-native from-scratch implementation of SSH for Windows, called PuTTY,
it's free, and it provides convenient GUIs for everything. It also
provides a convenient key agent in the form of a system tray applet, and
it has a CLI app which is a drop-in replacement for that "ssh" program
called by Git.

If you decide to try this approach, you can roll like this:

1. Install PuTTY.

2. Make sure you can run its SSH key agent (it's named pageant.exe).
You might later want to make it start automatically at login.

3. Run puttygen.exe to convert your OpenSSH key to the native PuTTY's
format and save it someplace.

4. Add the key to the agent (click on the agent, and it will show you a GUI
dialog for that).

5. Set GIT_SSH_COMMAND to "plink.exe" (without the double quotes).

6. Verify Git works with Github OK.

7. If all went well, make sure that GIT_SSH_COMMAND is set permanently.

8. Next time, after logging in, all you need to do is to run the agent
(unless it's configured to autostart) and add the key to it.

[1] https://www.putty.org/

Wei Hu

unread,
Sep 13, 2023, 3:19:42 PM9/13/23
to git-for-windows
OK, I will try to solve my problem according to the method you mentioned. Thank you very much for your patience. I'm sorry to trouble you as a novice on many minor issues. Thank you again.


--
You received this message because you are subscribed to the Google Groups "git-for-windows" group.
To unsubscribe from this group and stop receiving emails from it, send an email to git-for-windo...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/git-for-windows/20230913190727.d6ymbg4mj4yahigo%40carbon.

Konstantin Khomoutov

unread,
Sep 14, 2023, 5:19:12 AM9/14/23
to git-for-windows
On Wed, Sep 13, 2023 at 10:07:29PM +0300, Konstantin Khomoutov wrote:

[...]
> - Make use of the fact the SSH client can be told to use a particular
> key (which it calls "identity") via its "-i" command-line parameter.
>
> With this approach you might make sure an appropriately crafted
> GIT_SSH_COMMAND variable is seen by Git each time you're trying to work
> with Github. For instance, it may read something like
>
> ssh -i /c/some/path/to/your/github_rsa_key
[...]

Well, there's a better way to achieve the same result: OpenSSH supports
per-host configuration, so you could create a text file named "config"
(without extension) in C:\Users\PreX\AppData\Roaming\SPB_Data\.ssh\
and make it read something like

Host github.com
IdentityFile /c/the/path/to/your/github/id_rsa

Then the SSH client will use that key when making connections to github.com.

Wei Hu

unread,
Sep 14, 2023, 9:28:52 AM9/14/23
to git-for-windows
I copy the files which I used for Github  authenticate to the "incorrect" path( xxx\Roaming\SPB_Data\.ssh\ ), and I try "git fetch" , it's works !
Limited by my English level and technical level, I cannot fully understand your suggestions. I tried to understand the meaning and made corresponding operations based on my own understanding. Thank you very much for your patient guidance, I am very happy to learn “$env:GIT_SSH_COMMAND="ssh -vv" and "$env:GIT_TRACE = 1". Hope you can be happy every day.
Reply all
Reply to author
Forward
0 new messages