Afficher un message
Vieux 21/09/2006, 11h52   #2
Per Hedeland
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: testing bounces using sendmail -bt

In article <1158674372.273496.75390@h48g2000cwc.googlegroups. com>
"gymshoes" <jschueler@tqis.com> writes:
>I've read the sendmail bat book, and I still don't understand how the
>bounce mechanism works. It seems that the built-in error delivery
>agent can be used to generate a bounce. But I don't see any reference
>in sendmail.cf to the following message:
> 550 5.1.1 foobar... User unknown
>
>Nor does Rule testing give the expected results:
> [root@mail content]# /usr/sbin/sendmail -bt
> ADDRESS TEST MODE (ruleset 3 NOT automatically invoked)
> Enter <ruleset> <address>
> > 3,0 foobar

> ...
> parse returns: $# local $: foobar


This check (normally) happens internally in sendmail, based on the
presence of the 'w' flag in the mailer definition - from doc/op/op.*:

w The user must have a valid account on this
machine, i.e., getpwnam must succeed. If not, the
mail is bounced. See also the MailBoxDatabase
option. This is required to get ".forward" capa-
bility.

Basically sendmail does a getpwnam() on the recipient name.

>I might conclude that the delivery agent triggers the bounce. But I've
>never seen this defined as part of the Delivery Agent specification.


You've seen a Delivery Agent specification? Where?:-) Anyway, it's
certainly conceivable for the delivery agent to generate and send a
*bounce* of its own, after all it's just another e-mail message - though
better would be for it to tell sendmail to do it by means of a non-zero
exit code, e.g. for this case (from sysexits.h):

#define EX_NOUSER 67 /* addressee unknown */

However leaving the decision to the delivery agent (via either of the
two alternatives above) is undesirable in the spam era, precisely
because it entails the sending of a bounce - the standard method of
having sendmail check internally, as well as any check implemented in
the rulesets, has the advantage of causing a rejection of the recipient
already in the SMTP dialogue.

--Per Hedeland
per@hedeland.org
  Réponse avec citation
 
Page generated in 0,05307 seconds with 9 queries