Open xobotyi opened 1 year ago
i am using the powershell ssh-agent and i get the same results under 22.04
2022/12/12 09:58:24 connecting to //./pipe/openssh-ssh-agent
2022/12/12 09:58:24 connected
2022/12/12 09:58:27 copy from pipe to stdout finished: pipe closed
2022/12/12 09:58:27 socat[4180] E write(5, 0x561f0be6d000, 5): Broken pipe
under 20.04 only the first two lines are printed
2022/12/12 10:06:49 connecting to //./pipe/openssh-ssh-agent
2022/12/12 10:06:49 connected
It is not related to socat. When i copy the old socat and related libs to 22.04 it still does not work It is not related to WSL1 or WSL2. I am using WSL2 with the same WSL-Linux-Kernel in both cases.
socat -V
socat by Gerhard Rieger and contributors - see www.dest-unreach.org
socat version 1.7.3.3 on Oct 26 2019 17:42:04
running on Linux version #1 SMP Wed Nov 23 01:01:46 UTC 2022, release 5.15.79.1-microsoft-standard-WSL2, machine x86_64
LD_LIBRARY_PATH=$PWD ./socat -V
socat by Gerhard Rieger and contributors - see www.dest-unreach.org
socat version 1.7.3.3 on Oct 26 2019 17:42:04
running on Linux version #1 SMP Wed Nov 23 01:01:46 UTC 2022, release 5.15.79.1-microsoft-standard-WSL2, machine x86_64
I was able to resolve this by updating the version of the OpenSSH agent that comes with Windows. There appear to be some new security features that break the backwards compatibility between the prepackaged Windows agent and the one in Ubuntu 22.04. I updated OpenSSH in Windows by using scoop (for the first time). I found this solution in the wsl-ssh-agent repo issues linked below.
I am using Microsofts (beta) flavour of OpenSSH and so far it has been working fine for me on Windows 11 22H2 and 23H2 with Ubuntu 22.04
Attempted to use it with fresh ubuntu installation, all packages are upgraded, git installed.
Keys being added to ssh-agent via keepassxc Relay is launched via following script
If i do
ssh-add -l
- it properly shows keys - all the same with host. BUT! Attempt to clone repo from remote fails on ssh key validationgit@github.com: Permission denied (publickey)
. (ssh config is empty)Assuming that host system has same keys - i retried same from host system - everything works fine. If i remove key from agend and add it manually in host system - verification fails. If i stop relay, start local agent and add key there - everything works fine.