SA Bugzilla – Bug 5463
enhance got_hit API for dynamic scores&descriptions
Last modified: 2009-08-06 09:29:45 UTC
Some plugins want to display a) a dynamic score and b) a dynamic description in the tags _DISPLAY_, _REPORT_, and _TESTSSCORES_. This is currently accomplished by direct access to data fields and/or calling _handle_hit() instead of got_hit() as it is/was described for some time in http://wiki.apache.org/spamassassin/PluginWritingTips I suggest a small extension of PerMsgStatus::got_hit() to provide a stable API for this. The appended patch does that by writing the score into Conf->{scoreset} and by introducing an optional description parameter.
Created attachment 3946 [details] Patch against SA 3.2.0 to extend the got_hit API
Bug 5463: enhance got_hit API for dynamic scores & descriptions (loosely based on the attached patch) Sending lib/Mail/SpamAssassin/PerMsgStatus.pm Sending lib/Mail/SpamAssassin/Plugin/Check.pm Committed revision 801707.