On 26 Dec 2009, at 14:59, Steve Atkins wrote:
(Writing and testing a robust SMTP submission client is tedious, though,
especially when you find you need to handle authentication. Pretty much every
language has solid SMTP libraries available for it, so unless you have some
unusual requirements you should take a look at libesmtp or Email::Send or
whatever the common way of doing SMTP in your language of choice is).
Tcl, which is usually installed alongside the portable tcllib, has a superb
SMTP implementation that supports everything and does it right (our very own
Marshall Rose wrote it originally, of course). Unfortunately, it expects to be
used in practical conditions, where you will construct the MIME message inside
the script, rather than feed it raw headers and body. That makes it unsuitable
for this little script, which I have now completed, and which now works, if
only I could find out why news servers keep removing articles in the group
range they advertise ...
If you want to see the world's smallest SMTP implementation for yourself (no
extensions, assumes eight-bit-clean, and generally cuts every possible corner),
I'll put the script up at:
http://get.sabahattin-gucukoglu.com/newsfetch
when done, or at any rate soon.
Cheers,
Sabahattin