You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@spamassassin.apache.org by David <si...@yahoo.com> on 2005/05/26 23:56:43 UTC
Locating the Source of a Hit in the Message Content
Hi,
I'm new to SpamAssassin, and I've been running some tests.
I've been using the get_report() method to get a report of the rules that were
triggered by a message.
Is there a method that can identify where in the content the rule was
triggered (e.g. a line number, or a regular expression with which I can locate
it, or ?)
Thanks!
Re: Locating the Source of a Hit in the Message Content
Posted by Matt Kettler <mk...@comcast.net>.
At 05:56 PM 5/26/2005, David wrote:
>I'm new to SpamAssassin, and I've been running some tests.
>
>I've been using the get_report() method to get a report of the rules that
>were
>triggered by a message.
>
>Is there a method that can identify where in the content the rule was
>triggered (e.g. a line number, or a regular expression with which I can
>locate
>it, or ?)
No. Sa doesn't keep track of that in the general case, although if you want
you can do one of two things:
1) run spamassassin with "-D rulesrun=255" which debugs all the rule running.
2) If you're really perplexed look at the rule that matched (grep RULE_NAME
/usr/share/spamassassin/*). Most SA rules are regexes and you can apply
the regex from the rule directly to the message.