Xref: utzoo comp.mail.sendmail:1423 comp.mail.misc:3039 Path: utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!usc!ucsd!nosc!logicon.arpa!Makey From: Makey@Logicon.COM (Jeff Makey) Newsgroups: comp.mail.sendmail,comp.mail.misc Subject: Re: Bouncing mail for expired users Message-ID: <615@logicon.arpa> Date: 7 Mar 90 19:48:26 GMT References: <5637@ur-cc.UUCP> Followup-To: comp.mail.sendmail Organization: Logicon, Inc., San Diego, California Lines: 31 I added the following line to ruleset zero in my sendmail.cf file: R$*<@NoMail> $#error$@67$:user cannot receive mail "67" == EX_NOUSER (be sure to double-check the value of EX_NOUSER in /usr/include/sysexits.h) and lines similar to the following in my aliases file: olduser:olduser@NoMail This results in SMTP exchanges such as: 220 Logicon.COM Sendmail 5.61/6.03 ready at Wed, 7 Mar 90 10:26:05 -0800 HELO Red-Baron.Logicon.COM 250 Logicon.COM Hello Red-Baron.Logicon.COM, pleased to meet you MAIL FROM: 250 ... Sender ok RCPT TO: 554 tony@NoMail... user cannot receive mail QUIT 221 Logicon.COM closing connection This is better than Karl's shell script because the body of the message is not transmitted. Note that the error code is 554 instead of 550 as it really ought to be according to RFC 821; I'm not sure how sendmail might be changed to correct this. :: Jeff Makey Department of Tautological Pleonasms and Superfluous Redundancies Department Disclaimer: Logicon doesn't even know we're running news. Internet: Makey@Logicon.COM UUCP: {nosc,ucsd}!logicon.com!Makey