Net::S...ue::FTP(3pm)
π Net::S...ue::FTP(3pm) π
okay bestie, so this page lives in User Contributed Perl Documentation and it's literally the glow-up era of Net::FTP. come sit with me π«Ά
β¨ NAME β¨
Net::SSLGlue::FTP β it extends Net::FTP so you get FTPS (SSL) and IPv6. slay. π
πΈ SYNOPSIS πΈ
use Net::SSLGlue::FTP;
# SSL right from start
my $ftps = Net::FTP->new( $host,
SSL => 1,
SSL_ca_path => ...
);
# SSL through upgrade of plain connection
my $ftp = Net::FTP->new( $host );
$ftp->starttls( SSL_ca_path => ... );
# change protection mode to unencrypted|encrypted
$ftp->prot('C'); # clear
$ftp->prot('P'); # protected
π¦ DESCRIPTION π¦
so Net::SSLGlue::FTP extends Net::FTP β meaning you have two whole vibes to choose from: start the connection directly with SSL, or roll in plain and then switch to SSL later with the starttls method (that's the AUTH TLS command, iykyk).
and if IO::Socket::IP or IO::Socket::INET6 are installed? it'll transparently use IPv6 too. no extra effort from you, it just does it. iconic. β¨
by default it will take care to verify the certificate according to the rules for FTP implemented in IO::Socket::SSL. yes bestie, safety first. π
π METHODS π
new
the new method of Net::FTP is now able to start directly with SSL when the argument SSL => 1 is given. and you can hand it the usual SSL_* parameters of IO::Socket::SSL right there in Net::FTP::new. it's giving effortless. π₯
starttls
if the connection is not yet SSLified, this one will issue the AUTH TLS command and change the object, so that SSL will now be used. glow-up in real time, no cap. π
peer_certificate ...
once the SSL connection is established you can use this method to get information about the certificate. see the IO::Socket::SSL documentation for the deets. π§
all of these methods can take the SSL_* parameter from IO::Socket::SSL to change the behavior of the SSL connection. the following parameters are especially useful:
SSL_ca_path, SSL_ca_file
specifies the path or a file where the CAs used for checking the certificates are located. this is typically etc/ssl/certs on UNIX systems. π
SSL_verify_mode
if set to 0, verification of the certificate will be disabled. by default it is set to 1, which means that the peer certificate is checked. don't turn this off unless you know what you're doing, bestie, fr fr. π
SSL_verifycn_name
usually the name given as the hostname in the constructor is used to verify the identity of the certificate. if you want to check the certificate against another name, you can specify it with this parameter. π
π SEE ALSO π
IO::Socket::SSLNet::FTPNet::SSLGlue::Socket
π COPYRIGHT π
this module is copyright (c) 2013, Steffen Ullrich. All Rights Reserved. this module is free software. it may be used, redistributed and/or modified under the same terms as Perl itself. π«Ά
and that's the whole page, bestie!! this was rendered with perl v5.36.0, dated 2022-12-06, for Net::S...ue::FTP(3pm). go forth and encrypt your FTP, you absolute icon π β¨πΈ
π¦ where this page comes from
- debian bookworm: libnet-sslglue-perl 1.058-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- debian trixie: libnet-sslglue-perl 1.058-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu noble: libnet-sslglue-perl 1.058-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu resolute: libnet-sslglue-perl 1.058-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu stonking: libnet-sslglue-perl 1.058-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms