Oct 31, 2012, 10:01 AM
Post #1 of 13
I'm attempting to write a script that logins via ssh and provides an output of a command. However, it seems that when I try to login using a complex password, it fails to authenticate. Here is an example...
Net::SSH::Perl ( Complex Password Fails? )
The below will fail to authenticate.
If I change the password on the remote user to simple word or a word with numbers it works fine.
my $host = 'x.x.x.x';
my $user = 'user';
my $password = 'P@ssw@rd!';
#-- set up a new connection
my $ssh = Net::SSH::Perl->new($host);
#-- execute the command
my($stdout, $stderr, $exit) = $ssh->cmd("uname -a");
Edit: Output of running the script when failing..
Permission denied at script.pl line 12
(This post was edited by ezilagel on Oct 31, 2012, 12:09 PM)