Closed mplattner closed 1 year ago
This might be related to the changes of #341. Also relevant: using KeeAgent v0.12.1, agent forwarding worked correctly with OpenSSH_7.6p1 Ubuntu-4ubuntu0.7, OpenSSL 1.0.2n 7 Dec 2017
on the remote host(s), but not with OpenSSH_9.0p1 Debian-1+b1, OpenSSL 3.0.4 21 Jun 2022
. For the latter version I got the result described in #341 (agent refused operation).
Using the build from https://github.com/dlech/KeeAgent/actions/runs/3198121096, I am experiencing almost the same thing. Except that for me, I can successfully connect from local to host1 and further from host1 to host2. However, once that "inner" connection is established, the agent stops working and I can't connect for example from local to host3. If I log out of host2 (dropping me back to host1), it starts working again.
Clients get stuck waiting between these two debug output lines:
debug1: rekey in after 134217728 blocks
XXX here XXX
debug1: get_agent_identities: bound agent to hostkey
Local is: OpenSSH_for_Windows_8.9p1, LibreSSL 3.4.3 Host1 is: OpenSSH_7.4p1, OpenSSL 1.0.2k-fips Host2 is: OpenSSH_5.3p1, OpenSSL 1.0.1e-fips 11 Feb 2013
It would be helpful if someone could set up a couple docker containers using docker compose to reproduce the problem.
See https://github.com/dlech/SshAgentLib/tree/master/docker for a couple of existing ones.
I've had a look at the existing Dockerfiles. I'm not sure about your expectations: you want a docker-compose file that sets up 2 SSH servers that are on the same network so that we can test ssh client --- (ssh agent) --> docker sshd 1 --- (ssh agent (via forwarding)) ---> docker sshd 2
, right?
Yes, if I understand the problem correctly, this seems like the minimum needed to reproduce the issue.
Do you have something in ~/.ssh/config
to enable agent forwarding since no one seems to be using the ssh -A
option?
I was finally able to reproduce some issues with the Windows OpenSSH agent using Tabby (#384 ) configured to use Windows OpenSSH (nothing related to agent forwarding but more along the lines of "after a while it stops working").
Awesome, thanks @dlech! 🎉
As briefly described in https://github.com/dlech/KeeAgent/issues/349#issuecomment-1257996972, when using v0.13.2, the agent hangs when I use agent forwarding, i.e., I try to open a nested ssh session.
Here's how to reproduce it, assuming a terminal opened on
myhost
:Once I close the hanging terminal on
myhost
, I can again connect to e.g.host1
, but see the same behavior once I try to use agent forwarding (again).Versions:
myhost
OS: Windows 10 21H2myhost
SSH client: OpenSSH_for_Windows_8.1p1, LibreSSL 3.0.2myhost
KeePass: 2.51.1myhost
KeeAgent: v0.13.2host1
andhost2
OS: Ubuntu 18.04.5 LTShost1
andhost2
SSH client: OpenSSH_7.6p1 Ubuntu-4ubuntu0.7, OpenSSL 1.0.2n 7 Dec 2017However, I see the same behavior when
host1
andhost2
are up-to-date Kali Linux machines withOpenSSH_9.0p1 Debian-1+b1, OpenSSL 3.0.4 21 Jun 2022
.Below is the output of the command
host1-prompt> ssh -vvv host2
(host1/2
being the Ubuntu 18.04.5/SSH 7.6 ones):Let me know if you need more info. Thanks!