Discussion:
spam_kill_level_maps
(too old to reply)
Per olof Ljungmark
2016-04-25 22:28:26 UTC
Permalink
We would like to have a different kill level for a couple of users, not
sure how to do that properly.

Tried

$sa_kill_level_deflt = 5.2; # triggers spam evasive actions

@spam_kill_level_maps = (
{
'***@example.com' => 4.0,
'***@example.com' => 4.0,
'***@example.com' => 4.0,
'.' => \$sa_kill_level_deflt,
}
);

But that did not work as expected, default kill level became
kill=34453251368

Anyone has a hint please?

Thanks!
Mark.Martinec+ (Mark Martinec)
2016-04-26 17:52:59 UTC
Permalink
Post by Per olof Ljungmark
We would like to have a different kill level for a couple of users, not
sure how to do that properly.
Tried
$sa_kill_level_deflt = 5.2; # triggers spam evasive actions
@spam_kill_level_maps = (
{
'.' => \$sa_kill_level_deflt,
}
);
But that did not work as expected, default kill level became
kill=34453251368
Anyone has a hint please?
Thanks!
The hash-type lookup does not support delayed dereferencing.
You should use one of the following two variants:

@spam_kill_level_maps = (
{
'***@example.com' => 4.0,
'***@example.com' => 4.0,
'***@example.com' => 4.0,
'.' => $sa_tag_level_deflt,
},
);

or (functionally equivalent, but uses a 'constant' lookup
table as a fallback):

@spam_kill_level_maps = (
{
'***@example.com' => 4.0,
'***@example.com' => 4.0,
'***@example.com' => 4.0,
},
\$sa_kill_level_deflt,
);


Mark
Per olof Ljungmark
2016-04-26 22:56:11 UTC
Permalink
Post by Mark.Martinec+ (Mark Martinec)
Post by Per olof Ljungmark
We would like to have a different kill level for a couple of users, not
sure how to do that properly.
Tried
$sa_kill_level_deflt = 5.2; # triggers spam evasive actions
@spam_kill_level_maps = (
{
'.' => \$sa_kill_level_deflt,
}
);
But that did not work as expected, default kill level became
kill=34453251368
Anyone has a hint please?
Thanks!
The hash-type lookup does not support delayed dereferencing.
@spam_kill_level_maps = (
{
'.' => $sa_tag_level_deflt,
},
);
or (functionally equivalent, but uses a 'constant' lookup
@spam_kill_level_maps = (
{
},
\$sa_kill_level_deflt,
);
Thank you, that worked fine!
Can one do the same with sa_tag2_level then?

Like

@sa_tag2_level_maps = (
{
'***@example.com' => 3.0,
'***@example.com' => 3.0,
},
\$sa_tag2_level_deflt,
);
Mark.Martinec+ (Mark Martinec)
2016-04-26 23:28:37 UTC
Permalink
Post by Per olof Ljungmark
Post by Mark.Martinec+ (Mark Martinec)
The hash-type lookup does not support delayed dereferencing.
@spam_kill_level_maps = (
{
'.' => $sa_tag_level_deflt,
},
);
or (functionally equivalent, but uses a 'constant' lookup
@spam_kill_level_maps = (
{
},
\$sa_kill_level_deflt,
);
Thank you, that worked fine!
Can one do the same with sa_tag2_level then?
Like
@sa_tag2_level_maps = (
{
},
\$sa_tag2_level_deflt,
);
Yes, same principles.

Mark
Per olof Ljungmark
2016-04-27 13:09:34 UTC
Permalink
Post by Mark.Martinec+ (Mark Martinec)
Post by Per olof Ljungmark
Post by Mark.Martinec+ (Mark Martinec)
The hash-type lookup does not support delayed dereferencing.
@spam_kill_level_maps = (
{
'.' => $sa_tag_level_deflt,
},
);
or (functionally equivalent, but uses a 'constant' lookup
@spam_kill_level_maps = (
{
},
\$sa_kill_level_deflt,
);
Thank you, that worked fine!
Can one do the same with sa_tag2_level then?
Like
@sa_tag2_level_maps = (
{
},
\$sa_tag2_level_deflt,
);
Yes, same principles.
Hm, the above gave me:

Error in config file "/usr/local/etc/amavisd.conf": Global symbol
"@sa_tag2_level_maps" requires explicit package name at
/usr/local/etc/amavisd.conf line 129.
Mark.Martinec+ (Mark Martinec)
2016-04-27 15:35:28 UTC
Permalink
Post by Per olof Ljungmark
Post by Mark.Martinec+ (Mark Martinec)
Post by Per olof Ljungmark
@sa_tag2_level_maps = (
{
},
\$sa_tag2_level_deflt,
);
Yes, same principles.
Error in config file "/usr/local/etc/amavisd.conf": Global symbol
/usr/local/etc/amavisd.conf line 129.
It is @spam_tag2_level, not @sa_tag2_level_maps.

@spam_tag2_level = (
{
'***@example.com' => 3.0,
'***@example.com' => 3.0,
},
\$sa_tag2_level_deflt,
);


A bit of naming inconsistency for historic/compatibility reasons.

Mark

Loading...