Use SSHTool to convert Putty Private Key to OpenSSH private key

浪子不回头ぞ 提交于 2019-12-11 01:06:07

问题


In my java project I create a SSH tunnel with a server. The tunnel is authenticated currently using a putty private key and plink. Does anybody know how to use the java SSHTool library to either convert a putty key to a openssh key or use SSHTool library to create a ssh tunnel using a putty key? Thank you.


回答1:


Jsch only accepts opensh keys, not the format that putty creates the keys in. You would have to convert them. Use puttygen.exe to convert to openssh, then use the openssh keyfile in jsch.



来源:https://stackoverflow.com/questions/6986609/use-sshtool-to-convert-putty-private-key-to-openssh-private-key

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!