in reply to Net::SCP::Expect RSA Fingerprint Problem
If the option StrictHostKeyChecking=no is passed to OpenSSH ssh client and no key exists on the known_hosts file for the target host, it will accept as good (and remembered for future connections) the first one received from the remote host.
Though, I don't see how extra options for ssh can be passed through Net::SCP::Expect.
Anyway, you can use Net::OpenSSH instead:
$ssh = Net::OpenSSH->new($host, user => $user, password => $password, master_opts => [-o => 'StrictHostKeyChecking= +no']); $ssh->scp_put(...); $ssh->scp_get(...);
Note that disabling strict host key checking has some security implications that you should be aware of.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: Net::SCP::Expect RSA Fingerprint Problem
by anshumangoyal (Scribe) on Jan 11, 2013 at 08:41 UTC | |
by space_monk (Chaplain) on Jan 11, 2013 at 09:35 UTC | |
by Anonymous Monk on Jun 26, 2015 at 06:41 UTC |
In Section
Seekers of Perl Wisdom