Gnus development mailing list
 help / color / mirror / Atom feed
* spamc invocation: move from procmail to Gnus
@ 2004-04-24 19:33 Vasily Korytov
  2004-04-25 11:32 ` Jonas Steverud
  2004-04-30  0:18 ` Kevin Ryde
  0 siblings, 2 replies; 8+ messages in thread
From: Vasily Korytov @ 2004-04-24 19:33 UTC (permalink / raw)


Hi everybody,

My mail is currently delivered like this:

,----
| unix% cat .forward 
| |/usr/local/bin/procmail
| unix% tail -4 .procmailrc 
| # make use of SpamAssassin
| #:0fw
| |/usr/local/bin/spamc || exit 0
| #|/usr/local/bin/spamassassin -L
| unix% grep DEFAULT .procmailrc 
| DEFAULT=$HOME/Maildir/
`----

I.e. it's fetched by fetchmail and other means and put in maildir by
procmail, preprocessed by spamassassin. I'm moving my home directory to
NFS and the host machine (k6-266/128m/ata) won't be able to easily
handle spamassassin. So I want to run spamc on client machines.

Oh, boy, I thought, that was done a thousand times. I've looked into
gnus.info and found the solution, that is to add (: function)
construction to nnmail-split-fancy, that calls `spamc -c`.
Unfortunately, that does not suit me: I definitely want spam scores in
message headers. Ok, there is also a solution with a
prescript/postscript -- but do they exist with maildir (for NFS I really
don't want mboxes)? If yes, we got to fix the docs, I think.

I've also looked into spam.el, but found the way, it offers, too
complicated, but uneffective. I simply want to have spamassassin scores
in message header before it gets delivered to a folder.

So, the question is: is there a way to preprocess message being
delivered from a maildir to Gnus with a command? I.e. feed it to some
program and continue other filter rules (I use nnmail-split-fancy) with
its output?

Thanks.

-- 
       I accept RFC3156 and RFC2440-compatible encrypted mail.
PGP key fingerprint: 3273 7F6F 7B87 5DD5 9848 05FB E442 86BC 2E6B 6831




^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: spamc invocation: move from procmail to Gnus
  2004-04-24 19:33 spamc invocation: move from procmail to Gnus Vasily Korytov
@ 2004-04-25 11:32 ` Jonas Steverud
  2004-04-25 19:38   ` Vasily Korytov
  2004-05-12 16:48   ` Ted Zlatanov
  2004-04-30  0:18 ` Kevin Ryde
  1 sibling, 2 replies; 8+ messages in thread
From: Jonas Steverud @ 2004-04-25 11:32 UTC (permalink / raw)


deskpot@despammed.com (Vasily Korytov) writes:

> Hi everybody,

Hello.
[...]
> I.e. it's fetched by fetchmail and other means and put in maildir by
> procmail, preprocessed by spamassassin. I'm moving my home directory to
> NFS and the host machine (k6-266/128m/ata) won't be able to easily
> handle spamassassin. So I want to run spamc on client machines.

I don't quite follow what you try to archive. I'm with you all the way
up to "run spamc on client machines." Will the client machines run
fetchmail and procmail?

> I've also looked into spam.el, but found the way, it offers, too
> complicated, but uneffective. I simply want to have spamassassin scores
> in message header before it gets delivered to a folder.

It might be so that you are looking at Gnus from the procmail/SA
angle but need to look at procmail/SA from the Gnus angle.

What does you do with the spam that SA detects? I.e. what does you do
with mails that has the "X-SPAM: yes" header? Do you score on it or do
you split such emails to a specific group? Does you use SA's training
capabilities or just the static rule check?

I'm not convinced spam.el can be used to use spamassassin as is but
need to be extended. This should be possible and definitely something
some here might help out with - since it is a feature that is needed. 

I had one long look at spam filtering in Gnus before selecting which
backend I should use and I found like you did that spamassassin is not
perfectly integrated into Gnus (yet) so I decided I should use
bogofilter instead and I'm quite happy with that result.

It is nontrivial to use spamassassin from inside Gnus, one way of
solving this is to decide if you have to use spamassassin or can
change to some other filter - or wait until SA is integrated.

Can you describe the thoughts behind your decisions why you arrived at
this solution?

-- 
(        http://hem.bredband.net/steverud/        !     Wei Wu Wei     )
(        Meaning of U2 Lyrics, Roleplaying        !  To Do Without Do  )




^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: spamc invocation: move from procmail to Gnus
  2004-04-25 11:32 ` Jonas Steverud
@ 2004-04-25 19:38   ` Vasily Korytov
  2004-04-26  7:24     ` Jonas Steverud
  2004-05-12 16:48   ` Ted Zlatanov
  1 sibling, 1 reply; 8+ messages in thread
From: Vasily Korytov @ 2004-04-25 19:38 UTC (permalink / raw)


On Sun, 25 Apr 2004 13:32:58 +0200, Jonas Steverud wrote:

>> I.e. it's fetched by fetchmail and other means and put in maildir by
>> procmail, preprocessed by spamassassin. I'm moving my home directory to
>> NFS and the host machine (k6-266/128m/ata) won't be able to easily
>> handle spamassassin. So I want to run spamc on client machines.
>
> I don't quite follow what you try to archive. I'm with you all the way
> up to "run spamc on client machines." Will the client machines run
> fetchmail and procmail?

No, they won't. Mail is put into the maildir by the same machine, that
is an NFS server with limited resources. Client machines are using that
maildir with NFS.

>> I've also looked into spam.el, but found the way, it offers, too
>> complicated, but uneffective. I simply want to have spamassassin scores
>> in message header before it gets delivered to a folder.
>
> It might be so that you are looking at Gnus from the procmail/SA
> angle but need to look at procmail/SA from the Gnus angle.

Maybe. =))

> What does you do with the spam that SA detects? I.e. what does you do
> with mails that has the "X-SPAM: yes" header? Do you score on it or do
> you split such emails to a specific group? Does you use SA's training
> capabilities or just the static rule check?

I use static rule check and splitting on X-Spam headers. But I really
need spamassassin reports in messages (I.e. why is it considered spam
or non-spam.)

> It is nontrivial to use spamassassin from inside Gnus, one way of
> solving this is to decide if you have to use spamassassin or can
> change to some other filter - or wait until SA is integrated.
>
> Can you describe the thoughts behind your decisions why you arrived at
> this solution?

Well... I don't know, it just works for me. =)) So I'd like to adapt
this scheme to changing environment. If this is not trivial, when I
have time, I'll take a closer look and see, what I can do here.

-- 
       I accept RFC3156 and RFC2440-compatible encrypted mail.
PGP key fingerprint: 3273 7F6F 7B87 5DD5 9848 05FB E442 86BC 2E6B 6831




^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: spamc invocation: move from procmail to Gnus
  2004-04-25 19:38   ` Vasily Korytov
@ 2004-04-26  7:24     ` Jonas Steverud
  2004-04-26 11:15       ` Vasily Korytov
  0 siblings, 1 reply; 8+ messages in thread
From: Jonas Steverud @ 2004-04-26  7:24 UTC (permalink / raw)


deskpot@despammed.com (Vasily Korytov) writes:

> On Sun, 25 Apr 2004 13:32:58 +0200, Jonas Steverud wrote:
[...]
>> Can you describe the thoughts behind your decisions why you arrived at
>> this solution?
>
> Well... I don't know, it just works for me. =)) So I'd like to adapt
> this scheme to changing environment. If this is not trivial, when I
> have time, I'll take a closer look and see, what I can do here.

I'm sorry, but I don't think I can help with this setup. I found
during my investigations that is was nontrivial - even very hard IMHO
- to get Gnus to call Spamassassin and gave up. If you can consider
switching to bogofilter it becomes trivial to use. The downside is
that you won't know what triggered the spam level (although I think
that bogofilter could tell you that if you feed it a false positive
manually, but I haven't checked the docs).

One solution that you probably already have thought of is to have
spamd run on a more resourceful server and have the mail server run
spamc, if spamc can work across a network and the mail server is not
that limited, which I guess it is.

-- 
(        http://hem.bredband.net/steverud/        !     Wei Wu Wei     )
(        Meaning of U2 Lyrics, Roleplaying        !  To Do Without Do  )




^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: spamc invocation: move from procmail to Gnus
  2004-04-26  7:24     ` Jonas Steverud
@ 2004-04-26 11:15       ` Vasily Korytov
  0 siblings, 0 replies; 8+ messages in thread
From: Vasily Korytov @ 2004-04-26 11:15 UTC (permalink / raw)


On Mon, 26 Apr 2004 09:24:30 +0200, Jonas Steverud wrote:

> I'm sorry, but I don't think I can help with this setup. I found
> during my investigations that is was nontrivial - even very hard IMHO
> - to get Gnus to call Spamassassin and gave up. If you can consider
> switching to bogofilter it becomes trivial to use. The downside is
> that you won't know what triggered the spam level (although I think
> that bogofilter could tell you that if you feed it a false positive
> manually, but I haven't checked the docs).

Using spamassassin from spam.el gives this results too. I consider this
nothing but awkward. =(( Maybe, it's really not from the Gnus angle (not
procmail and SA's), but I don't understand that yet.

Another solution is to write `spamc -c` output to some other file, and
retrieve it as needed. But also a hack to SA is needed: current output
it too trimmed down. I'll think of it.

> One solution that you probably already have thought of is to have
> spamd run on a more resourceful server and have the mail server run
> spamc, if spamc can work across a network and the mail server is not
> that limited, which I guess it is.

I've already thought of it. Unfortunately, there're no other full-time
on machines in this subnet. =((

Thanks.

-- 
       I accept RFC3156 and RFC2440-compatible encrypted mail.
PGP key fingerprint: 3273 7F6F 7B87 5DD5 9848 05FB E442 86BC 2E6B 6831




^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: spamc invocation: move from procmail to Gnus
  2004-04-24 19:33 spamc invocation: move from procmail to Gnus Vasily Korytov
  2004-04-25 11:32 ` Jonas Steverud
@ 2004-04-30  0:18 ` Kevin Ryde
  1 sibling, 0 replies; 8+ messages in thread
From: Kevin Ryde @ 2004-04-30  0:18 UTC (permalink / raw)


deskpot@despammed.com (Vasily Korytov) writes:
>
> add (: function)
> construction to nnmail-split-fancy, that calls `spamc -c`.
> Unfortunately, that does not suit me: I definitely want spam scores in
> message headers.

When I used that setup (isp despam now, it got too slow for my poor
pc), I usually did a separate spamassassin run to get its scores, to
investigate false positives or negatives.

Use at your own risk, etc, etc.

    (defun my-spamassassin-test ()
      (interactive)
      (gnus-summary-show-article t)
      (set-buffer "*Article*")
      (shell-command-on-region (point-min) (point-max) "spamassassin -t")
      (other-window 1)
      (beginning-of-buffer)
      (re-search-forward "^X-Spam" (point-max) t)
      (beginning-of-line)
      (recenter 3))



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: spamc invocation: move from procmail to Gnus
  2004-04-25 11:32 ` Jonas Steverud
  2004-04-25 19:38   ` Vasily Korytov
@ 2004-05-12 16:48   ` Ted Zlatanov
  2004-05-13  8:26     ` Jonas Steverud
  1 sibling, 1 reply; 8+ messages in thread
From: Ted Zlatanov @ 2004-05-12 16:48 UTC (permalink / raw)


On Sun, 25 Apr 2004, tvrud@bredband.net wrote:

> I'm not convinced spam.el can be used to use spamassassin as is but
> need to be extended. This should be possible and definitely
> something some here might help out with - since it is a feature that
> is needed.
> 
> I had one long look at spam filtering in Gnus before selecting which
> backend I should use and I found like you did that spamassassin is
> not perfectly integrated into Gnus (yet) so I decided I should use
> bogofilter instead and I'm quite happy with that result.

I did not write the SA support in spam.el, but I'm wondering what is
missing from it.  Can you or someone else interested in better SA
support explain?

Note there are two ways of using SA, server-based (user just sees
X-Spam-Status) and user-based.  The two are very different, so please
explain what is needed for each one.

Ted



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: spamc invocation: move from procmail to Gnus
  2004-05-12 16:48   ` Ted Zlatanov
@ 2004-05-13  8:26     ` Jonas Steverud
  0 siblings, 0 replies; 8+ messages in thread
From: Jonas Steverud @ 2004-05-13  8:26 UTC (permalink / raw)


Ted Zlatanov <tzz@lifelogs.com> writes:

> On Sun, 25 Apr 2004, tvrud@bredband.net wrote:
[...]
> I did not write the SA support in spam.el, but I'm wondering what is
> missing from it.  Can you or someone else interested in better SA
> support explain?

As far as I could tell then, there where no support for Spamassassin
at all in spam.el. It might have changed after I did my decision.

-- 
(        http://hem.bredband.net/steverud/        !     Wei Wu Wei     )
(        Meaning of U2 Lyrics, Roleplaying        !  To Do Without Do  )




^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2004-05-13  8:26 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-04-24 19:33 spamc invocation: move from procmail to Gnus Vasily Korytov
2004-04-25 11:32 ` Jonas Steverud
2004-04-25 19:38   ` Vasily Korytov
2004-04-26  7:24     ` Jonas Steverud
2004-04-26 11:15       ` Vasily Korytov
2004-05-12 16:48   ` Ted Zlatanov
2004-05-13  8:26     ` Jonas Steverud
2004-04-30  0:18 ` Kevin Ryde

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).