From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Jens Knoell" Subject: Re: Proper procedure for bounced mails? Date: Mon, 22 Jul 2002 16:45:37 -0600 Sender: linux-admin-owner@vger.kernel.org Message-ID: <036f01c231d1$92843920$0264a8c0@wombie> References: <00fe01c2315a$0b292a20$0264a8c0@wombie><20020722122857.GH29481@piku.org.uk><02f801c231b5$8ab03300$0264a8c0@wombie> <15676.29971.791712.488355@cerise.nosuchdomain.co.uk> Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Return-path: List-Id: Content-Type: text/plain; charset="us-ascii" To: Linux Admin ML From: "Glynn Clements" > Whereabouts in the message delivery chain does the script sit? Does it > process the message as it comes in, or is it fed the message after the > SMTP server has acknowledged its acceptance? It uses the Mlocal part of sendmail's config, so it is possible to use the exit code, as far as I know. But to the best of my knowledge, it's not possible to return some custom string to indicate the reason for failure, is there? > For the former (e.g. if the script is registered as a mailer in > sendmail.cf, or called from a procmail rule), it should simply report > a failure via its exit code, so that the SMTP server indicates an > error immediately. This eliminates the need to construct a bounce > message. Absolutely - IF I can somehow return a custom error message like "Message appears to be spam - look at http://blah.blubb.bleh/spampolicy.html" or some such...? > For the latter, then it needs to send a bounce message to the > *envelope* sender address; sending bounces to any other address may > result in your domain being blacklisted by mailing lists. That's what I currently do, I think. Good point about mimicking sendmail's generic error messages... I hadn't thought of doing it that way. Thanks a lot Jens