l0ser140 / ssh-agent-wsl2

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Description

Allows you to use ssh keys through ssh-agent on Windows in WSL2 machine. Works with Keepass KeeAgent plugin or open-ssh-agent. This approach uses npiperelay.exe to forward Windows named pipe into WSL2.

Dependencies

  • WSL2. You can check version with wsl --list --verbose
  • socat installed in your WSL.
sudo apt install socat

Installation

  • Dowload repository as zip
  • Extract files
  • Run install.sh in WSL2
sudo install.sh

Manual installation

  • download npiperelay and extract npiperelay.exe to /usr/local/bin/npiperelay.exe
  • copy wsl-ssh-agent-forwarder to /usr/local/bin/wsl-ssh-agent-forwarder
  • set execution permissions to wsl-ssh-agent-forwarder and npiperelay.exe
  • add line . /usr/local/bin/wsl-ssh-agent-forwarder to ~/.bashrc

Origin

Based on strarsis Gist

About

License:GNU General Public License v3.0


Languages

Language:Shell 96.2%Language:Batchfile 3.8%