[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#47709: Some scripts way, way out of date



On Mon, Oct 18, 1999 at 03:42:09AM -0400, Mike Bilow wrote:
> For example, the 'mailto.pl' script dating from 1995 is mostly an example
> of how to crack a query string and exec 'sendmail,' neither of which are
> especially good ideas.  As of Perl 5, the 'CGI.pm' module is a standard
> component and its use is strongly preferred instead of manually cracking
> query strings.  Also, invoking 'sendmail' is deprecated in favor of using
> CPAN packages 'Mail::Mailer' or at least 'Net::SMTP' now.  Anyone who
> actually tried using the supplied 'mailto.pl' script as an example of how
> to write a CGI program would be wasting their time.

I agree that mailto.pl is out of date, and that CGI.pm should be used.

However, I disagree with the thought process which suggests that Net::SMTP
is in any way a replacement for sendmail.  The semantics are totally
different (sendmail queues while Net::SMTP does not).

Also, for this reason, using Mail::Mailer is not always advisable --
when you use it you're implying that mail system semantics are
irrelevant to your application.

In most (not all) cases, for cgi work, you want to use a mail system
which queues mail.  In most cases where you need to use a mail system
which does not queue mail you also don't want that mail being delivered
from inside a cgi program.

So while I agree, overall, with the points you're making I disagree on
this one particular issue.

Thanks,

-- 
Raul


Reply to: