Re: [Exim] Wish to hack Exim: quietly discarding a message v…

トップ ページ
このメッセージを削除
このメッセージに返信
著者: Philip Hazel
日付:  
To: Juan Carlos Castro y Castro
CC: exim-users
題目: Re: [Exim] Wish to hack Exim: quietly discarding a message via transport filter
On Thu, 24 Jun 2004, Juan Carlos Castro y Castro wrote:

> I'd like a transport filter to be able to return a special value that
> would instruct Exim to abort delivery of a mesage, no frezing, no
> bouncing, no nothing.


A transport filter is a *filter*; it runs in parallel with the
actual delivery process. Therefore, the message is being delivered while
it is running. For example, a connection to a remote host has already
been made, and the envelope has been transmitted. All you could do would
be to kill the delivery untidily in the middle.

Transport filters are intended for making modifications when messages
are transmitted. They are not intended to make decisions about delivery.
That is the job of the routers and the system filter and/or the ACLs.
If you want to discard a recipient based on message content, you should
find a way of doing it earlier. For example, you can write a
local_scan() function to do this a reception time.

> I suppose I should be making changes around line 1090, where the code
> below is. The question is, what exactly should I do here to discard the
> message?


There is nothing you can do here that will discard the message.

--
Philip Hazel            University of Cambridge Computing Service,
ph10@???      Cambridge, England. Phone: +44 1223 334714.
Get the Exim 4 book:    http://www.uit.co.uk/exim-book