[Mimedefang] Filtering on SMTP authentication but would like to check for virus

Andrew Watkins andrew at dcs.bbk.ac.uk
Fri Mar 16 12:41:30 EDT 2012


But the problem is that you should only use the read_commands_file() in 
filter_sender() or filter_recipient().

So, the basic logic of mimedefang in my case is:
    filter_relay
	- check SMTP connection
    filter_sender
	- check senders address, check auth
    filter_recipient
	- check recipient, greylisting
    filter_begin
	- Virus,
    filter
	- MIME, etc
    filter_end
	- SpamAssassin

So the logic I want is:

    filter_relay
    filter_sender
	- CHECK for SMTP authentication (set $GLOBALauth=YES)
    filter_recipient
	- skip if SMTP authentication ($GLOBALauth=YES)
   filter_begin
	- Check for Virus
	- if SMTP authentication ($GLOBALauth=YES) then 
ACCEPT_AND_NO_MORE_FILTERING


I just wanted to avoid a global variable.

Anyway, thanks for your help.

Andrew


On 03/16/12 13:37, David F. Skoll wrote:
> On Fri, 16 Mar 2012 13:09:00 +0000
> Andrew Watkins<andrew at dcs.bbk.ac.uk>  wrote:
>
>> Problem is that virus checking is done in filter_begin which is not
>> called if the user has SMTP authentication
>
>> Any ideas?
>
> Rework the logic of your filter so that only certain things are skipped
> for authenticated users.  Obviously, you can't use ACCEPT_AND_NO_MORE_FILTERING
> anywhere. ;)
>
> Put the logic in filter_begin or filter_end or wherever you do your
> spam-scanning.
>
> Regards,
>
> David.
> _______________________________________________
> 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 MIMEDefang at lists.roaringpenguin.com
> http://lists.roaringpenguin.com/mailman/listinfo/mimedefang


-- 
Andrew Watkins * Birkbeck College
http://notallmicrosoft.blogspot.com/



More information about the MIMEDefang mailing list