[prev in list] [next in list] [prev in thread] [next in thread]
List: amavis-user
Subject: Re: [AMaViS-user] amavisd-new-20021116 patch4
From: Mark Martinec <Mark.Martinec () ijs ! si>
Date: 2002-11-27 16:12:38
[Download RAW message or body]
Chris,
| > @local_domains = qw( .example.com .example.org );
| > @bypass_spam_checks_acl = qw( !.example.com !.example.org . );
| >... would BYPASS spam checks for ALL recipients (catchall dot),
| >EXCEPT for recipients in domains example.com and example.org,
| >including their subdomains (leading dot).
|
| Thanks for the suggestion Mark. Unfortunately, it don't work :(
|
| I get this in my log on HUPping the server:
| | Nov 26 20:33:29 rowan.oak-wood.co.uk amavisd[4670]: ANTI-SPAM code NOT loaded
| I haven't entirely got to grips with your lookup code yet, but it looks
| to me as if this:
|
| | elsif (lookup("\001", \%bypass_virus_checks, \@bypass_virus_checks_acl,
| | $bypass_virus_checks_re)) {
| | # do a simple test which (by using an impossible domain)
| | # which should indicate if the lookup tables contain a catchall
| | $extra_code_antivirus = undef;
| is tripping up on the "." in @bypass_spam_checks_acl
Ah, yes. This simple-minded test is too simple-minded.
This should do better (line numbers won't match, but it should do):
===============
--- amavisd~ Tue Nov 26 17:39:55 2002
+++ amavisd Wed Nov 27 17:05:28 2002
@@ -5191,18 +5191,18 @@
if (!@av_scanners) {
$extra_code_antivirus = undef;
-} elsif (lookup("\001", \%bypass_virus_checks, \@bypass_virus_checks_acl,
- $bypass_virus_checks_re)) {
- # do a simple test which (by using an impossible domain)
- # which should indicate if the lookup tables contain a catchall
+} elsif (!%bypass_virus_checks &&
+ @bypass_virus_checks_acl==1 && @bypass_virus_checks_acl[0] eq '.') {
+ # do a simple-minded test to make it easy to turn off virus checks
$extra_code_antivirus = undef;
} else {
eval $extra_code_antivirus or die "Problem in the antivirus code: $@";
$extra_code_antivirus = 1; # release memory occupied by the source code
}
-if (lookup("\001", \%bypass_spam_checks, \@bypass_spam_checks_acl,
- $bypass_spam_checks_re)) {
+if (!%bypass_spam_checks &&
+ @bypass_spam_checks_acl==1 && @bypass_spam_checks_acl[0] eq '.') {
+ # do a simple-minded test to make it easy to turn off spam checks
$extra_code_antispam = undef;
} else {
eval $extra_code_antispam or die "Problem in the antispam code: $@";
===============
Thanks for finding a bug!
Mark
-------------------------------------------------------
This SF.net email is sponsored by: Get the new Palm Tungsten T
handheld. Power & Color in a compact size!
http://ads.sourceforge.net/cgi-bin/redirect.pl?palm0002en
_______________________________________________
AMaViS-user mailing list
AMaViS-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/amavis-user
AMaViS-FAQ:http://www.amavis.org/amavis-faq.php3
AMaViS-HowTos:http://www.amavis.org/howto/
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic