From: Rene Schickbauer

> walt wrote:
>> I am new to Perl and want to connect to an smtp server on port 25 and
then
>> send it the helo, mail from:, rcpt to:, data, commands but I would
also like
>> to evaluate the response from the smtp server.
>> 
>> Has anyone got a script or can point me in the right direction?
> 
> A simple example on how to work with sockets can be found here:
> <http://www.osix.net/modules/article/?id=441>
> 
> (just google for: perl io::socket tutorial)
> 
> As for the protocol, Wikipedia has a good article on that, look 
> especially at the included example:
> 
>
<http://en.wikipedia.org/wiki/Simple_Mail_Transfer_Protocol#SMTP_transpo
rt_example>
> 
> You should really also have a look at the official documentation of
SMTP:
> <http://www.faqs.org/rfcs/rfc821.html>
> 
> And yes, i know RFC821 is deprecated, and there are newer, more 
> complicated, more feature-rich versions of the protocol available. But
i 
> have yet to find a server that doesn't understand the basics layed out

> in this specification.

I believe the current document is RFC2821. It mostly extends the
original protocol and tries to clarify some explanations. So 821 is
still a proper subset. I do think it is best to read 821 first. One
difference that does matter is that the CR+LF pair as line terminator is
now explicitly required by both 2821 and 2822. That was not clear in the
originals.

Bob McConnell

--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to