Gnus development mailing list
 help / color / mirror / Atom feed
* new spam.el functionality
@ 2003-01-23 17:35 Ted Zlatanov
  2003-01-23 22:52 ` Andreas Fuchs
  0 siblings, 1 reply; 5+ messages in thread
From: Ted Zlatanov @ 2003-01-23 17:35 UTC (permalink / raw)


Regular expression matching against headers.  You define a list of
regular expressions in spam-regex-headers-spam and
spam-regex-headers-ham, and set spam-use-regex-headers to t.
spam-split will invoke spam-check-regex-headers.

Pretty simple, really, but probably useful to people like a user on
the gnus newsgroups I responded to today, who get X-Spam-Flag: YES
headers and such added to their mail.  The default header regexps are
for the X-Spam-Flag header currently.

The manual was updated as well.

Ted



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

* Re: new spam.el functionality
  2003-01-23 17:35 new spam.el functionality Ted Zlatanov
@ 2003-01-23 22:52 ` Andreas Fuchs
  2003-01-24  2:44   ` Ted Zlatanov
  2003-01-24  3:23   ` Raja R Harinath
  0 siblings, 2 replies; 5+ messages in thread
From: Andreas Fuchs @ 2003-01-23 22:52 UTC (permalink / raw)


Today, Ted Zlatanov <tzz@lifelogs.com> wrote:
> Regular expression matching against headers.  You define a list of
> regular expressions in spam-regex-headers-spam and
> spam-regex-headers-ham, and set spam-use-regex-headers to t.
> spam-split will invoke spam-check-regex-headers.

Hm, isn't whitelist and blacklist functionality a subset of the regex
matching functionality? Could these three be merged easily?

Happy hacking,
-- 
Andreas Fuchs, <asf@acm.org>, asf@jabber.at, antifuchs




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

* Re: new spam.el functionality
  2003-01-23 22:52 ` Andreas Fuchs
@ 2003-01-24  2:44   ` Ted Zlatanov
  2003-01-24  3:23   ` Raja R Harinath
  1 sibling, 0 replies; 5+ messages in thread
From: Ted Zlatanov @ 2003-01-24  2:44 UTC (permalink / raw)


On Thu, 23 Jan 2003, asf@void.at wrote:
> Today, Ted Zlatanov <tzz@lifelogs.com> wrote:
>> Regular expression matching against headers.  You define a list of
>> regular expressions in spam-regex-headers-spam and
>> spam-regex-headers-ham, and set spam-use-regex-headers to t.
>> spam-split will invoke spam-check-regex-headers.
> 
> Hm, isn't whitelist and blacklist functionality a subset of the
> regex matching functionality? Could these three be merged easily?

I wouldn't merge them, they have very different purposes and
white/blacklists store their lists in files, but you could certainly
emulate white/blacklists with regex-headers if you wanted.  I don't
think anyone would.

Ted




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

* Re: new spam.el functionality
  2003-01-23 22:52 ` Andreas Fuchs
  2003-01-24  2:44   ` Ted Zlatanov
@ 2003-01-24  3:23   ` Raja R Harinath
  2003-01-24  4:33     ` Ted Zlatanov
  1 sibling, 1 reply; 5+ messages in thread
From: Raja R Harinath @ 2003-01-24  3:23 UTC (permalink / raw)


Hi,

Andreas Fuchs <asf@void.at> writes:

> Today, Ted Zlatanov <tzz@lifelogs.com> wrote:
>> Regular expression matching against headers.  You define a list of
>> regular expressions in spam-regex-headers-spam and
>> spam-regex-headers-ham, and set spam-use-regex-headers to t.
>> spam-split will invoke spam-check-regex-headers.
>
> Hm, isn't whitelist and blacklist functionality a subset of the regex
> matching functionality? Could these three be merged easily?

Also applies to spam-check-bogofilter-headers.

- Hari
-- 
Raja R Harinath ------------------------------ harinath@cs.umn.edu



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

* Re: new spam.el functionality
  2003-01-24  3:23   ` Raja R Harinath
@ 2003-01-24  4:33     ` Ted Zlatanov
  0 siblings, 0 replies; 5+ messages in thread
From: Ted Zlatanov @ 2003-01-24  4:33 UTC (permalink / raw)
  Cc: ding

On Thu, 23 Jan 2003, harinath@cs.umn.edu wrote:
> Andreas Fuchs <asf@void.at> writes:

>> Hm, isn't whitelist and blacklist functionality a subset of the
>> regex matching functionality? Could these three be merged easily?
> 
> Also applies to spam-check-bogofilter-headers.

spam-check-bogofilter-headers uses (message-fetch-field
spam-bogofilter-header), then extracts the spamicity score.

spam-check-blacklist (whitelists are similar) uses
(message-fetch-field "from"), and stores its regular expressions in a
file.  It's intended for large numbers of entries in the blacklist.

spam-check-regex-headers does a re-search-forward call on the message.

I think those are three pretty different functions.  At best, you can
come up with an improved message-fetch-field.  But maybe I'm
misunderstanding.

I'm not sure what you and Andreas are proposing: a merging of the user
interface variables, or a simplification of the code?

I am against merging of the user interface variables.  Users want a
Bogofilter header check, not Lisp code.  I don't think anyone would
prefer to add "^X-Bogosity: Yes.*spamicity=\\([0-9]+\\)" to the
spam-spam-regex-headers, to setting spam-use-bogofilter-headers to t.
If they want, they can do it, but spam.el is intended to be simple and
easy to use and configure.  Does anyone disagree with this?

Simplification of the code is a good goal, but sometimes it's not
necessary.  Can you produce code or a patch that shows how you would
like to abstract spam-check-bogofilter-headers, spam-check-blacklist,
and spam-check-regex-headers into one function?

Ted

p.s. should spam-*-regex-headers be "regexp-headers" instead of
"regex-headers"?

p.p.s. should it be just "regexp" instead of "regexp-headers", since
it does a match on whatever is available in the article buffer while
splitting?  spam-check-regex-headers is intended for headers, but
could be used on the body.




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

end of thread, other threads:[~2003-01-24  4:33 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-01-23 17:35 new spam.el functionality Ted Zlatanov
2003-01-23 22:52 ` Andreas Fuchs
2003-01-24  2:44   ` Ted Zlatanov
2003-01-24  3:23   ` Raja R Harinath
2003-01-24  4:33     ` Ted Zlatanov

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).