$identity = "id_dsa"; $host = "target"; $usr = "user"; my %args; $args{identity_files} = $identity; $ssh = Net::SSH::Perl->new($host, %args); $ssh->login($usr); #### Can't use string ("id_dsa") as an ARRAY ref while "strict refs" in use at /usr/lib/perl5/site_perl/5.6.1/Net/SSH/Perl/Auth/RSA.pm line 36.