PuttyAgent now supports openssh/cygwin/msys

Version vom 11. Mai 2014, 08:37 Uhr von Niki (Diskussion | Beiträge)

(Unterschied) ← Nächstältere Version | Aktuelle Version (Unterschied) | Nächstjüngere Version → (Unterschied)
Wechseln zu: Navigation, Suche

For a long time, I extensively used the plugin "PuttyAgent" for KeePass as an SSH key agent. However, unfortunately the protocol (at least the transfer protocol) of PuTTYs implementation and openssh (cygwin, MSYS) are not compatible. So far I avoided openssh and used wrappers to plink.exe (e.g., for rsync or unison). But that becomes more and more a pain. And finally, with git and git-annex I gave up: I looked for putty agent to ssh-agent gateways and they indeed exist. However, another application residing in RAM makes it unhandy. So I decided to just add the support to PuttyAgent...

Version 3.0 of PuttyAgent for KeePass also supports cygwin's or MSYS ssh version by creating a cygwin-style socket file.

First of all, go into the plugin settings and enable the support. It's disabled by default. You need to supply a path for the socket file. The file must not exist and KeePass must have write permissions to create the socket file. As example, take c:\usr\apps\KeePass\keepass.sock


Then, go to control panel, User Accounts and select "Change my environment variables". Add the variable $SSH_AUTH_SOCK:


Please note that you can just use Windows path (no /cygdrive/c/... or /c/... required). Cygwin and MSYS are able to convert this path appropriately. And this way, the socket can be shared between cygwin and MSYS applications (e.g. git) at the same time!

Finally, open a cygwin terminal, check if the environment variable is set and points to the correct file and test the connection:




The newest version of the plugin is available here: http://keepass.info/plugins.html


  • PuTTY
  • PuTTY Agent
  • Pageant
  • ssh-agent
  • cygwin
  • msys
  • openssh agent
  • PuTTY pageant openssh gateway
  • cygwin socket


asmus meinte …

25. Februar 2015

Danke schoen!!


Michael meinte …

25. Juli 2015

Gibts das auch mit KeePass 2.x Kompatibilität?


Niki meinte …

Niki meinte …

25. Juli 2015

More specifically: http://lechnology.com/software/keeagent/usage/tips-and-tricks/#client-mode-with-pageant

I migrated to KP2 on my own ...


Michael meinte …

25. Juli 2015
  • wow* That's what I call a very fast answer! Thanks! :)

Yeah, saw that plugin a few minutes after asking here. Got it working already. Thanks again, I appreciate your help.


Niki meinte …

8. Januar 2017


--Niki (Diskussion)
Meine Werkzeuge