#1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2002
    Posts
    1
    Rep Power
    0

    Question Using Net::FTP over a secure ftp connectin


    hi

    I need to transfer files (some big db sql dumps, every night) over a secure ftp connection, the ftpd server being on port 22 and using a SSL/TLS encryption mechanism.

    Are there Perl packages available to handle Net::FTP objects over encrypted connections ?
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Apr 2000
    Location
    germany
    Posts
    122
    Rep Power
    17

    Cool what about ssh


    I realized an automated secure file transfer (running as a cron job every hour) using the SSH SCP (secure copy) command and the perl module Expect. Looked like this:

    use Expect;

    my $prog = '/usr/bin/scp';
    my $user = 'someone@localhost';

    $scp = Expect->spawn($prog, ("$user:FILE", '/tmp'));

    (...)


    Consult the module docs and SSH docs for more information. This is definetely a way to implement secure file transfers using standard tools.
  4. #3
  5. No Profile Picture
    Devshed Newbie (0 - 499 posts)

    Join Date
    Apr 2002
    Location
    The Emerald City
    Posts
    289
    Rep Power
    12
    There is a Net::SFTP module that you could try. There is also a Net::SCP module as well. Both are available from CPAN (and probably ASPN, too, if you use windows).

    http://search.cpan.org/doc/IVAN/Net-SCP-0.06/SCP.pm
    http://search.cpan.org/doc/BTROTT/Ne...ib/Net/SFTP.pm

    jaa

IMN logo majestic logo threadwatch logo seochat tools logo