Does this work with Windows Subsystem for Linux (WSL) ?
opened this issue · comments
Does this work with Windows Subsystem for Linux (WSL) ?
I investigated this in #43. I don't think it's possible to use ssh-pageant, because the WSL environment doesn't have access to the Windows APIs needed to talk to Pageant.
oh ok tyvm!
Does this insider build 14951 sound like it will fix the problem? There is also a Channel 9 video about it
Hmm, maybe. It's a good start if you can now see native processes, but ssh-pageant still needs access itself to both AF_UNIX
sockets and Windows APIs. A Linux binary would never have the latter, and so I'd expect the subsystems are still isolated within a given process. (unlike Cygwin et al.)
Maybe it could be done with multiple processes. Say, a ssh-pageant-win
that talks to Pageant and translates on a pipe or stdin/stdout, and then a ssh-pageant-lin
which routes that to the AF_UNIX
socket that Linux programs want for the agent. I think you could probably even handle the second part with socat
. I'm not sure how this would handle multiple connections though.
That's a pretty significant departure though. Basically all of main.c would be rewritten to be a native Windows process, and only winpgntc.c would be the same, which is already basically just copied from PuTTY.
A small advertisement: I have implemented this using the new Win32 interop facilities shipped with Creators Update as a modification of ssh-pageant
. If the OP is still interested (and running CU or newer), my version is now available at https://github.com/vuori/weasel-pageant
@vuori I see you implemented the pipe idea, nice! I'd be happy to list your project in the Links section of my readme, if you'd like to send a PR.
👍