ssh2 icon indicating copy to clipboard operation
ssh2 copied to clipboard

Add support for auth-agent (server)

Open 131 opened this issue 6 years ago • 11 comments

The [email protected] channel is not implemented on the server side.

The server need to acknowledge the request by opening a channel (see openssh source code )

Again, this is an amazing project and i'm very excited being able to help, even if it's just a little.

131 avatar Apr 19 '19 19:04 131

Ok, i ended up doing it \o/

This PR relies on a requirement PR in ssh2-stream

131 avatar Apr 20 '19 11:04 131

All good since https://github.com/mscdex/ssh2-streams/pull/132 has landed (just rebased it)

131 avatar Jul 02 '19 21:07 131

I've updated the PR with requested changes

131 avatar Jul 08 '19 17:07 131

Also can you add a test for this? I understand it will (currently) require the master ssh2-streams branch and that's ok.

mscdex avatar Jul 08 '19 17:07 mscdex

I've updated the PR again, (with the style change - sorry for that). I'm looking into the "test" part now

131 avatar Jul 08 '19 19:07 131

So, testing the agent stream requires me to spawn a "real" ssh-agent. Is that okay with you ?

131 avatar Jul 08 '19 20:07 131

Do we really need ssh-agent to be running? I think just spinning up a unix socket server locally may be enough? Also we might need to skip this test on Windows, unless there is some way we can detect we're in WSL in which case (i'm assuming) unix sockets are available?

mscdex avatar Sep 14 '19 20:09 mscdex

I've updated the PR with ssh-streams2 bump (as this is needed) so the tests can pass.

I've spend some time on it, but i cannot find a way to test openssh_authAgent without running a proper agent server.

If spawning an external server bother you, i've wrote a pure js ssh-agent server, but that's another story. Also, this PR is working fine under WSL (as i'm working only on this stack)

131 avatar Sep 16 '19 20:09 131

I'll rebase that for 1@

131 avatar Jun 24 '21 08:06 131

Hi @mscdex , is there anything more you want on this one ?

131 avatar Jun 25 '21 12:06 131

Hi @mscdex, is there any other problem with this pull request? i'm implementing a ssh proxy and this feature is required to implement public key login on destination. i also tested changes on my local env and its working

alireza-ebrahimi avatar Aug 26 '24 08:08 alireza-ebrahimi