Mail::Abuse::Processor::Score - Assign a score to an abuse report
use Mail::Abuse::Processor::Score; use Mail::Abuse::Report; my $p = new Mail::Abuse::Processor::Score; my $report = new Mail::Abuse::Report (processors => [ $p ]); # ... other pieces of code that configure the report ...
This class allows for the computation of a score value, that can be stored in the
Mail::Abuse::Report object itself. The score can be used by other processes for different purposes, such as priorizing incident handling, noise rejection and filtering, etc.
The way in which the score is calculated is controlled by the following configuration entries:
Can accept multiple (value, regexp) pairs, where value is a numeric constant that will be added to the "current" score of a report and regexp is a Perl regular expression that contains no whitespace. Spaces in the regular expression must be written in terms of
Each regexp will be matched in sequence over the unprocessed text of the report, and if it matches, the corresponding value will be added to the report's score. Negative values cause the score to decrease, as expected.
Can accept multiple (score, regexp) pairs just as in score report text, but what will be matched is the type of each incident already in the report.
Enforce this value as the minimum score for a report.
Enforce this value as the maximum score for a report.
When set to a true value, debug information will be issued using
In the case where no configuration entry matches or is specified, the score will be set to zero.
The following functions are implemented.
Mail::Abuse::Report object as an argument and performs the processing action required.
None by default.
$Log: Score.pm,v $ Revision 1.3 2005/03/22 16:07:31 lem Implemented minimum and maximum scores
Revision 1.2 2005/03/16 22:24:42 lem Add m to regexps.
Revision 1.1 2005/03/16 22:13:23 lem Added Mail::Abuse::Processor::Score to calculate scores for the abuse reports
This code and all accompanying software comes with NO WARRANTY. You use it at your own risk.
This code and all accompanying software can be used freely under the same terms as Perl itself.
Luis E. Muñoz <firstname.lastname@example.org>