On Sat, Jul 02, 2005 at 12:56:05PM -0700, Michael Hall wrote:
> On Sat, Jul 02, 2005 at 07:55:49AM +0100, Mike Woods wrote:
>
> > >Just in case, to prevent someone misunderstanding: we are talking about
> > >empty string (no characters), and not about NULL character in a string.
> >
> > Yes i know :)
> >
> > However most ldap attributes require some data which is why im not sure
> > a null value can be entered!
>
> Correct, I think we'll have to do something like use '<>' in the LDAP
> attribute entry and hack the code accordingly.
Here's a quick and dirty patch:
--- amavisd Wed Jun 29 22:49:06 2005
+++ amavisd.test Sat Jul 2 13:32:21 2005
@@ -12639,6 +12639,7 @@
my($wblist);
my($keys_ref,$rhs_ref) = make_query_keys($sender,0,0);
my(@keys) = @$keys_ref;
+ @keys = qw(<> @ @.) if $sender eq '';
do_log(5,sprintf("wbl: (LDAP) query keys: %s",
join(', ',map{"\"$_\""[EMAIL PROTECTED])));
$wblist = lookup(0,$recip, Amavis::Lookup::LDAPattr->new(
In LDAP you need to use '<>' for your white/black list entry. Not sure
if this will be the long term solution but it does work for now.
Jul 2 13:18:42 ukiah amavis[11655]: (11655-01) wbl: checking sender <>
Jul 2 13:18:42 ukiah amavis[11655]: (11655-01) query_keys: , @, @.
Jul 2 13:18:42 ukiah amavis[11655]: (11655-01) wbl: (LDAP) query keys: "<>", "@
", "@."
Jul 2 13:18:42 ukiah amavis[11655]: (11655-01) lookup_ldap_attr(amavisblacklist
sender) "[EMAIL PROTECTED]" result=(ARRAY(0xb3b7434))
Jul 2 13:18:42 ukiah amavis[11655]: (11655-01) lookup => true, "[EMAIL
PROTECTED]
e.org" matches, result=["@SSDD.org"], matching_key="/cached/"
Jul 2 13:18:42 ukiah amavis[11655]: (11655-01) lookup_ldap_attr(amaviswhitelist
sender) "[EMAIL PROTECTED]" result=(ARRAY(0xb2d5c28))
Jul 2 13:18:42 ukiah amavis[11655]: (11655-01) lookup => true, "[EMAIL
PROTECTED]
e.org" matches, result=["@spamassassin.apache.org","<>"], matching_key="/cached/
"
Jul 2 13:18:42 ukiah amavis[11655]: (11655-01) wbl: (LDAP) recip <[EMAIL
PROTECTED]
de.org> whitelisted sender <>
Jul 2 13:18:42 ukiah amavis[11655]: (11655-01) query_keys: [EMAIL PROTECTED],
mhall@, riverside.org, .riverside.org, .org, .
Jul 2 13:18:42 ukiah amavis[11655]: (11655-01) lookup_hash([EMAIL PROTECTED])
, no matches
Jul 2 13:18:42 ukiah amavis[11655]: (11655-01) lookup (score_sender) => undef,
"[EMAIL PROTECTED]" does not match
Jul 2 13:18:42 ukiah amavis[11655]: (11655-01) wbl: whitelisted sender <>
Jul 2 13:18:42 ukiah amavis[11655]: (11655-01) sender white/blacklisted, skippi
ng spam_scan
--
No, no, nurse! I said SLIP off his SPECTACLES!!
Mike Hall,
System Admin - Rock Island Communications <[EMAIL PROTECTED]>
System Admin - riverside.org, ssdd.org <[EMAIL PROTECTED]>
-------------------------------------------------------
SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
from IBM. Find simple to follow Roadmaps, straightforward articles,
informative Webcasts and more! Get everything you need to get up to
speed, fast. http://ads.osdn.com/?ad_id=7477&alloc_id=16492&op=click
_______________________________________________
AMaViS-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/amavis-user
AMaViS-FAQ:http://www.amavis.org/amavis-faq.php3
AMaViS-HowTos:http://www.amavis.org/howto/