Quantcast
Channel: BlogoSfera » DATA
Viewing all articles
Browse latest Browse all 64

How to read the password from the text file in perl

$
0
0

I am new to perl script, The below code is downloading the files from sftp server. #!/usr/bin/perl use strict; use warnings; use Net::SFTP::Foreign; my $sftp = Net::SFTP::Foreign->new( 'auser@sftp.rent.com', password => 'auser123', more => ['-v'] ); $sftp->get('outgoing/DATA.ZIP', '/home/sar/') or die "unable to retrieve copy: ".$sftp->error; $sftp->disconnect; Here i have hard codded the password, I want to [...]

The post How to read the password from the text file in perl appeared first on BlogoSfera.


Viewing all articles
Browse latest Browse all 64

Trending Articles