From Net::SMTP:

DESCRIPTION

This module implements a client interface to the SMTP and ESMTP protocol, enabling a perl5 application to talk to SMTP servers. This documentation assumes that you are familiar with the concepts of the SMTP protocol described in RFC2821. With IO::Socket::SSL installed it also provides support for implicit and explicit TLS encryption, i.e. SMTPS or SMTP+STARTTLS.

The Net::SMTP class is a subclass of Net::Cmd and (depending on avaibility) of IO::Socket::IP, IO::Socket::INET6 or IO::Socket::INET.

From Net::SMTP::TLS:

DESCRIPTION

Net::SMTP::TLS is a TLS and AUTH capable SMTP client which offers an interface that users will find familiar from Net::SMTP. Net::SMTP::TLS implements a subset of the methods provided by that module, but certainly not (yet) a complete mirror image of that API.

The methods supported by Net::SMTP::TLS are used in the above example. Though self explanatory for the most part, please see the perldoc for Net::SMTP if you are unclear.

From Net::SMTPS:

DESCRIPTION

This module implements a wrapper for Net::SMTP, enabling over-SSL/STARTTLS support. This module inherits most of all the methods from Net::SMTP(2.X). You may use all the friendly options that came bundled with Net::SMTP. You can control the SSL usage with the options of new() constructor method. 'doSSL' option is the switch, and, If you would like to control detailed SSL settings, you can set SSL_* options that are brought from IO::Socket::SSL. Please see the document of IO::Socket::SSL about these options detail.

Just one method difference from the Net::SMTP, you can select SMTP AUTH mechanism as the third option of auth() method.

As of Version 3.10 of Net::SMTP(libnet) includes SSL/STARTTLS capabilities, so this wrapper module's significance disappareing.

Net::SMTP is the older module with numerous options; Net::SMTP::TLS and Net::SMTPS are newer modules with less options that tried to simplify the process to some degree (but do not match all the functionality of Net::SMTP as a result). All three appear to use IO::Socket::SSL under the hood to provide TLS encryption (SMTPS or SMTP+STARTTLS).

Hope that helps.


In reply to Re: send mail with STARTTLS by atcroft
in thread send mail with STARTTLS by Anonymous Monk

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.