Net::S...::POP3(3pm)

πŸ“¦
version 1.058 Β· 6 versions
, in debian bookworm, debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking

πŸ’– Net::SSLGlue::POP3 β€” the glow-up your Net::POP3 always deserved πŸ’–

okay bestie, gather round, because this little module is literally the moment Net::POP3 got its SSL era. ✨


🌸 NAME 🌸

Net::SSLGlue::POP3 β€” it makes Net::POP3 able to use SSL. that's it. that's the whole job. and it ate. πŸ’…


✨ SYNOPSIS ✨

use Net::SSLGlue::POP3;
my $pop3s = Net::POP3->new( $host,
    SSL => 1,
    SSL_ca_path => ...
);

my $pop3 = Net::POP3->new( $host );
$pop3->starttls( SSL_ca_path => ... );

see how easy that is?? two whole vibes: start secure from the jump, OR start plain and then upgrade mid-conversation. iconic behavior honestly. πŸ¦‹


πŸ’œ DESCRIPTION πŸ’œ

Net::SSLGlue::POP3 extends Net::POP3 so you can either start directly with SSL, or switch over to SSL later using the STLS command. pick your fighter. πŸŽ€

and by default?? it takes care to verify the certificate according to the rules for POP3 implemented in IO::Socket::SSL. no slacking on security, we don't do that here. πŸ”₯


πŸ‘‘ METHODS πŸ‘‘

  • new β€” the new method of Net::POP3 is now able to start directly with SSL when the argument "<SSL =" 1>> is given. and when that happens, it does NOT make an IO::Socket::INET object β€” it makes an IO::Socket::SSL object instead, bestie. glow up complete. you can hand it the usual SSL_* parameters of IO::Socket::SSL right there in Net::POP3::new. 🌟
  • starttls β€” if the connection isn't SSLified yet, it issues the STLS command and changes the object so that SSL will now be used. the usual SSL_* parameters of IO::Socket::SSL will be given. it's giving mid-arc transformation scene. 🧚
  • peer_certificate ... β€” once the SSL connection is established, the object is derived from IO::Socket::SSL, so you can use this method to get info about the certificate. go read the IO::Socket::SSL documentation for the deets, iykyk. πŸ“œ

all of these methods can take the SSL_* parameter from IO::Socket::SSL to change the behavior of the SSL connection. and these ones in particular?? especially useful:

🌈 the SSL_* parameters that matter 🌈

  • SSL_ca_path, SSL_ca_file β€” specifies the path or a file where the CAs used for checking the certificates are located. on UNIX systems this is typically etc/ssl/certs. πŸ—‚οΈ
  • SSL_verify_mode β€” if set to 0, verification of the certificate will be disabled. by default it is set to 1, which means the peer certificate is checked. so like, default = protected, and 0 = living dangerously, your choice babe. 🚨
  • SSL_verifycn_name β€” usually the name given as the hostname in the constructor is used to verify the identity of the certificate. but if you wanna check the certificate against another name, you specify it with this parameter. plot twist friendly. πŸ’«

🫢 SEE ALSO 🫢

IO::Socket::SSL, Net::POP3 β€” go read them, they're the supporting cast and they understood the assignment. πŸ’–


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 Net::S...::POP3(3pm) from perl v5.36.0, dated 2022-12-06 β€” mwah, slay, periodt. πŸ’…βœ¨πŸŒΈ

πŸ“¦ where this page comes from