On Tue, 2006-11-14 at 10:37 -0600, Mike Campbell wrote: > I'm trying to figure out what order the various filter_* routines are > called during a session. I can find where filter_begin and filter_end > are called but what about the order of the following: > > filter_relay > filter_sender > filter_helo (which apparently is going away) > filter_recipient > > Can anyone give me the order in which they are executed? Specifically I > have a filter_relay and looks like I need a filter_sender in my > environment but need to know how they are evaluated. Would it be best to > just combine the code from these procedures into a single procedure? If > so which is the best to use?
In general, you can put all your filter code in filter_end. Depending
on your goals and environment, you may want to put code in
filter_(relay|sender|recipient). From `man mimedefang-filter`
SMTP FLOW
This section illustrates the flow of messages through MIMEDefang.
1. INITIAL CONNECTION
If you invoked mimedefang with the -r option and have
defined a filter_relay routine, it is called.
2. SMTP HELO COMMAND
The HELO string is stored internally, but no filter
functions are called.
3. SMTP MAIL FROM: COMMAND
If you invoked mimedefang with the -s option and have
defined a filter_sender routine, it is called.
4. SMTP RCPT TO: COMMAND
If you invoked mimedefang with the -t option and have
defined a filter_recipient routine, it is called.
5. END OF SMTP DATA
filter_begin is called. For each MIME part, filter is
called. Then filter_end is called.
signature.asc
Description: This is a digitally signed message part
_______________________________________________ NOTE: If there is a disclaimer or other legal boilerplate in the above message, it is NULL AND VOID. You may ignore it. Visit http://www.mimedefang.org and http://www.roaringpenguin.com MIMEDefang mailing list [email protected] http://lists.roaringpenguin.com/mailman/listinfo/mimedefang

