Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: SpamAssassin: users

spamass-milter -r doesn't work for me

 

 

SpamAssassin users RSS feed   Index | Next | Previous | View Threaded


lehmann at schwedler

Feb 8, 2010, 6:50 AM

Post #1 of 5 (682 views)
Permalink
spamass-milter -r doesn't work for me

I've problems telling spamass-milter to reject mails.

spamass-milter - Version 0.3.1

I start it by:

/usr/local/sbin/spamass-milter -p /var/run/spamass.sock -b
spambox [at] ourdomain -u smmsp -f -r 15 -- -d spamscanner.ourdomain.com

It should reject spam mails with a score higher 15, else send the spam
to spambox [at] ourdomain you tell me whats wrong?

Christoph


--
Christoph Lehmann
Dr. Ralf Schwedler e.K. Amtsgericht Pinneberg, HRA 5609 PI
Internet / Sicherheit Bankverbindung:
Sparkasse Westholstein
Steinbrückstrasse 13b BLZ 222 500 20
25524 Itzehoe, Germany Konto-Nr. 11 00 84 323
T +49 4821 40 87 58 International Account Number
0700-SCHWEDLER IBAN DE05 2225 0020 0110 0843 23
F +49 4821 40 87 59 BIC HSHNDEH1IZH
---- ----
www.schwedler.com Steuer-Nr. 18019 34593
lehmann [at] schwedler USt.-Id. DE 214230181


andreas at xss

Feb 8, 2010, 12:22 PM

Post #2 of 5 (645 views)
Permalink
Re: spamass-milter -r doesn't work for me [In reply to]

Hi Christoph!

Am 08.02.2010 15:50, schrieb Christoph Lehmann:
> I've problems telling spamass-milter to reject mails.
>
> spamass-milter - Version 0.3.1
>
> I start it by:
>
> /usr/local/sbin/spamass-milter -p /var/run/spamass.sock -b
> spambox [at] ourdomain -u smmsp -f -r 15 -- -d spamscanner.ourdomain.com
>
> It should reject spam mails with a score higher 15, else send the spam
> to spambox [at] ourdomain you tell me whats wrong?
>

You didn't describe the symptoms of your problems, so it's
hard to tell you what's wrong...

You described what you want your setup to do, but not what it
actually does instead.

But it looks like you have the same problems with spamass-milter
as I have and which I described a few days ago on this list (see
<http://marc.info/?l=spamassassin-users&m=126537672706931&w=2>)

I still don't know how to solve this problem and I haven't
got an answer to my mail, though.

KR

- andreas

--
Andreas Haumer | mailto:andreas [at] xss
*x Software + Systeme | http://www.xss.co.at/
Karmarschgasse 51/2/20 | Tel: +43-1-6060114-0
A-1100 Vienna, Austria | Fax: +43-1-6060114-71


shanew at shanew

Feb 8, 2010, 12:47 PM

Post #3 of 5 (636 views)
Permalink
Re: spamass-milter -r doesn't work for me [In reply to]

I think you're both misunderstanding what the -b option does, and
reading the man page, I can see how it could be more explicit.

In any case, the -b option is used to send rejected mail to a
specified email address (in case you want to inspect it). Someone can
correct me if I'm wrong, but I think what you're looking to do can't
be done in spamass-milter. I would recommend a procmail recipe to do
that instead.

On Mon, 8 Feb 2010, Andreas Haumer wrote:

> Hi Christoph!
>
> Am 08.02.2010 15:50, schrieb Christoph Lehmann:
>> I've problems telling spamass-milter to reject mails.
>>
>> spamass-milter - Version 0.3.1
>>
>> I start it by:
>>
>> /usr/local/sbin/spamass-milter -p /var/run/spamass.sock -b
>> spambox [at] ourdomain -u smmsp -f -r 15 -- -d spamscanner.ourdomain.com
>>
>> It should reject spam mails with a score higher 15, else send the spam
>> to spambox [at] ourdomain you tell me whats wrong?
>>
>
> You didn't describe the symptoms of your problems, so it's
> hard to tell you what's wrong...
>
> You described what you want your setup to do, but not what it
> actually does instead.
>
> But it looks like you have the same problems with spamass-milter
> as I have and which I described a few days ago on this list (see
> <http://marc.info/?l=spamassassin-users&m=126537672706931&w=2>)
>
> I still don't know how to solve this problem and I haven't
> got an answer to my mail, though.
>
> KR
>
> - andreas
>
>

--
Public key #7BBC68D9 at | Shane Williams
http://pgp.mit.edu/ | System Admin - UT iSchool
=----------------------------------+-------------------------------
All syllogisms contain three lines | shanew [at] shanew
Therefore this is not a syllogism | www.ischool.utexas.edu/~shanew


andreas at xss

Feb 8, 2010, 1:27 PM

Post #4 of 5 (640 views)
Permalink
Re: spamass-milter -r doesn't work for me [In reply to]

Hi!

Am 08.02.2010 21:47, schrieb Shane Williams:
> I think you're both misunderstanding what the -b option does, and
> reading the man page, I can see how it could be more explicit.
>
> In any case, the -b option is used to send rejected mail to a
> specified email address (in case you want to inspect it). Someone can

As I understand the manual page, the "-b" option is not about
rejected mails but about tagged mails.

Tagged mails usually are a superset of rejected mails (i.e.
if the "reject" score is larger than the "tag" score)
A rejected mail will always be a tagged mail, but a tagged
mail not necessarily is a rejected mail.

So the question is (logically): should the handling of the "-b" option
include the whole set of tagged mails or the set of tagged mails minus
the set of rejected mails?

I (and I guess Christoph, too) want the "-b" option only to handle
the set of tagged mails reduced by the set of rejected mails but it
looks like it currently applies to the whole set of tagged mails.
The "reject" thing currently is just an additional feature, independent
of the "redirect" feature.

> correct me if I'm wrong, but I think what you're looking to do can't
> be done in spamass-milter. I would recommend a procmail recipe to do
> that instead.
>

Hm, I don't really like the procmail approach. It would add
an additional component in the chain. I'd rather rely on the
sendmail & milter components.

I just checked the source code of spamass-milter and it looks
like it does some extra steps just to provide a behaviour I
don't like...

Look at spamass-milter.cpp around line 450:

[...]
if (do_reject)
{
debug(D_MISC, "Rejecting");
smfi_setreply(ctx, "550", "5.7.1", "Blocked by
SpamAssassin");


if (flag_bucket)
{
/* If we also want a copy of the spam, shell out
to sendmail and
send another copy. The milter API will not
let you send the
message AND return a failure code to the
sender, so this is
the only way to do it. */
[...]

And then it continues with a popen() call just to start
sendmail on order to send the previously rejected mail to
the recipient given with the "-b" option.
(This also explains why in case of rejected mails the sendmail
logfiles look differently regarding the handling of headers)

I think I'm going to add another option to spamass-milter
just to tell it not to send a copy of the rejected mail.
It shouldn't be that hard to implement something working
the way I like, it might be harder to implement someting
the spamass-milter maintainer (and the community) likes.

Comments?

- andreas

--
Andreas Haumer | mailto:andreas [at] xss
*x Software + Systeme | http://www.xss.co.at/
Karmarschgasse 51/2/20 | Tel: +43-1-6060114-0
A-1100 Vienna, Austria | Fax: +43-1-6060114-71


shanew at shanew

Feb 8, 2010, 2:05 PM

Post #5 of 5 (644 views)
Permalink
Re: spamass-milter -r doesn't work for me [In reply to]

On Mon, 8 Feb 2010, Andreas Haumer wrote:

> Hi!
>
> Am 08.02.2010 21:47, schrieb Shane Williams:
>> I think you're both misunderstanding what the -b option does, and
>> reading the man page, I can see how it could be more explicit.
>>
>> In any case, the -b option is used to send rejected mail to a
>> specified email address (in case you want to inspect it). Someone can
>
> As I understand the manual page, the "-b" option is not about
> rejected mails but about tagged mails.
>
> Tagged mails usually are a superset of rejected mails (i.e.
> if the "reject" score is larger than the "tag" score)
> A rejected mail will always be a tagged mail, but a tagged
> mail not necessarily is a rejected mail.

My interpretation of the -b option is based on previous usage of it.
I agree that what the man page says it does is completely different,
and someone should change the way that's written.


> So the question is (logically): should the handling of the "-b" option
> include the whole set of tagged mails or the set of tagged mails minus
> the set of rejected mails?
>
> I (and I guess Christoph, too) want the "-b" option only to handle
> the set of tagged mails reduced by the set of rejected mails but it
> looks like it currently applies to the whole set of tagged mails.
> The "reject" thing currently is just an additional feature, independent
> of the "redirect" feature.

I would say there's a need for both. I found the -b option useful
when I first turned it on and wanted to make sure spamass-milter was
behaving as expected without the risk of losing legitimate mail. I
can also see a use for the feature you and Christoph are after, but I
wouldn't over-ride the existing behavior.


>> correct me if I'm wrong, but I think what you're looking to do can't
>> be done in spamass-milter. I would recommend a procmail recipe to do
>> that instead.
>
> Hm, I don't really like the procmail approach. It would add
> an additional component in the chain. I'd rather rely on the
> sendmail & milter components.

What you're wanting doesn't have to occur at transaction time, and so
probably shouldn't, IMHO. Procmail (or perhaps something else like
MailScanner) would be the next logical place in the mail-processing
chain to handle these, which is why I suggested it. At it's simplest,
I think it looks like this (not tested).

:0c
* ^X-Spam-Status: Yes,
feedmespam [at] wherever

But, to each his own :-)

--
Public key #7BBC68D9 at | Shane Williams
http://pgp.mit.edu/ | System Admin - UT iSchool
=----------------------------------+-------------------------------
All syllogisms contain three lines | shanew [at] shanew
Therefore this is not a syllogism | www.ischool.utexas.edu/~shanew

SpamAssassin users RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.