- It can be unsafe to run sendmail as daemon, not to use it as a client
to send mail out.
The code used to do so *is* a potential security risk. There are many
references as to why. Start here in clpm, then move onto Google
- Postfix has a binary named sendmail too and Postfix _is_ secure.
I use Postfix as well for the same reason, but *never* use the client
without good reason. Maybe that's just me, but I prefer to know *exactly*
what's being sent out and to where. Again, the code referenced by the OP
does not insure that (no mention of taint checking or validation of the
variable used for the message - very dangerous). Just because the
*binary* is "secure" doesn't mean the human interface can't make it
"un-secure".
- Does Net::SMTP will queue your messages in case of mail server outage?
There is a 'SkipBad' setting, which will still send email to valid
addresses even if other addresses are seen as bad by the server. There is
also the 'Debug' setting which will allow you to see the conversation
between the script and the server - so you can see *why* the address is
seen as bad. And queuing a message ... that's the responsibility of the
server - the client should only be concerned with sending the email.
Either it's sent or not
On the chance your email(s) are not sent, the script should let you know
is some efficient fashion (like maintaining a log and ... checking the log
to see if all went well

). And, if it's a critical activity to send
out emails, you should be writing the emails out to file in case they get
lost in transit. Queuing the messages will do not good if they get lost
in the queue because of some fatal error to your system - or due to some
error on the part of the "human interface" (aka user error)
- Will it try multiple servers?
And why would you want to

If you have that many issues with the
server, the problem isn't the script, it's the server you're sending to

Sending to multiple servers seems more like sending spam than legit
email. There should not be any reason to send to multiple SMTP servers.
Do you do this with your favorite email client? The same messages? If
so, again, the problem lies with your ISP, not your client
Basicaly if you don't mind (potentialy) loosing mail Net::SMTP is fine,
otherwise sendmail is the way to go.
There's nothing wrong with the Net::SMTP module. All your statements are
really based upon FUD. I guess you could argue the same way. I doubt it,
but I guess you could
--
Jim
Copyright notice: all code written by the author in this post is
released under the GPL.
http://www.gnu.org/licenses/gpl.txt
for more information.
a fortune quote ...
Grandpa Charnock's Law: You never really learn to swear until
you learn to drive.