...and so your test is probably not doing what you think it is. spoke too soon.
Or maybe you intended to discard the output as a side-effect, do it explicitly with /dev/null or some such.
UPDATE:
#Globals are bad mojo my $remotemachine = $ARGV[0]; # see if keys exist if (-e !"/$home/.ssh/id_dsa.pub"){ system('ssh-keygen', '-t', 'dsa'); } #Only use semi-colon's after do{} blocks. system('scp', "/$ENV{HOME}/.ssh/id_dsa.pub, "$remotemachine://home/$EN +V{USER}/.ssh/authorized_keys2"); system('ssh-agent', q(sh -c 'ssh-add < /dev/null && bash')); exec('ssh', $remotemachine); #exit (0); #That's the default
--
In Bob We Trust, All Others Bring Data.
In reply to Re: Ssh Keys
by belg4mit
in thread Ssh Keys
by j^2
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |