Perl's Net::(SSH vs SSH2 vs OpenSSH) — how should I compare them?

a 夏天 提交于 2019-12-04 02:30:17
indiv

The Net::OpenSSH documentation has a section describing the pros and cons of each. Here are some excerpts related to the ones you are asking about, but the documentation lists more:

Net::SSH is just a wrapper around any SSH binary commands available on the machine. It can be very slow as they establish a new SSH connection for every operation performed.

Net::SSH2 is much better than Net::SSH::Perl, but not completely stable yet. It can be very difficult to install on some specific operative systems and its API is also limited, in the same way as Net::SSH::Perl.

Net::OpenSSH has a very perlish interface. Most operations are performed in a fashion very similar to that of the Perl builtins and common modules (i.e. IPC::Open2).

However, choice of platform may limit your options.

On the other hand, Net::OpenSSH does not work on Windows, not even under Cygwin.

Granted, the list is biased towards Net::OpenSSH, but it gives you an idea of the major differences between the modules.

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