grom has asked for the wisdom of the Perl Monks concerning the following question:
Hello everybody!
I'm trying to establish a SSH connection between two windows servers using Net::SSH::Any.
Why this module? It fits all my requirements (SFTP, keep-alive connection...) so I would love to keep going with this one.
Fact is, it works with password authentication but I need to use the key authentication now.
First of all, I've generated a pair of public/private keys and converted them into OpenSSH. All using PuttyGen.
To test them, I tried with Putty and it works perfectly.
When I tried with my perl script, it fails with "Authentication failed"
Here is my script:
Does anyone see something I missed? Thanks!use Net::SSH::Any; $instance = "myserver.mydomain"; $path = "C:\\Temp\\PrivateKey_openssh.ppk"; $ssh = Net::SSH::Any->new($instance, user => "mydomain\\mylogin", key_ +path => $path); $ssh->error and die $ssh->error; print "SSH connection accepted\n\n";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Usage of key authentication with Net::SSH::Any
by Corion (Patriarch) on Dec 10, 2013 at 09:34 UTC | |
by Anonymous Monk on Dec 11, 2013 at 13:44 UTC | |
by grom (Initiate) on Dec 11, 2013 at 13:46 UTC | |
by salva (Canon) on Dec 11, 2013 at 14:07 UTC | |
by grom (Initiate) on Dec 12, 2013 at 08:51 UTC | |
by salva (Canon) on Dec 12, 2013 at 09:13 UTC | |
|