On Thu, 9 May 2002, Rob Siemborski wrote: > On Thu, 9 May 2002, Marc G. Fournier wrote: > > > So, unless I'm overlooking something, is there some way of injecting 'per > > user' options at the lmtp (and beyond) level? > > Sieve scripting allows such flexability: > > Want to disable the filter? > Don't filter on the header that SA injects. > Want to whitelist a mailing list? > Don't apply the SA header filter to messages from that address. > What to set a different threshhold? > Use the comparison extention (which was discussed earlier, it's not > implemented but it's probably something we want). > > The key is that SA can put enough information in the header to let sieve > have pretty fine-grained control over the message.
Okay, here's what I need ... I need a filter that will work in Sieve, using the comparison extension discussed earlier, that will re-calculate the score of an email message based on the message coming through as: X-Spam-Status: Yes, hits=9.1 required=5.0 tests=FROM_ENDS_IN_NUMS, MAILTO_TO_SPAM_ADDR,SUPERLONG_LINE,MAILTO_LINK,CHARSET_FARAWAY, CTYPE_JUST_HTML,SUBJ_ALL_CAPS version=2.20 X-Spam-Flag: YES X-Spam-Level: ********* X-Spam-Checker-Version: SpamAssassin 2.20 (devel $Id: SpamAssassin.pm, v 1.77 2002/04/06 19:28:30 hughescr Exp $) X-Spam-Prev-Content-Type: text/html; charset="ks_c_5601-1987" SPAM: -------------------- Start SpamAssassin results ---------------------- SPAM: This mail is probably spam. The original message has been altered SPAM: so you can recognise or block similar unwanted mail in future. SPAM: See http://spamassassin.org/tag/ for more details. SPAM: SPAM: Content analysis details: (9.1 hits, 5 required) SPAM: Hit! (1.0 point) From: ends in numbers SPAM: Hit! (1.3 points) URI: Includes a link to a likely spammer email address SPAM: Hit! (-0.4 points) BODY: Contains a line >=199 characters long SPAM: Hit! (0.0 points) BODY: Includes a URL link to send an email SPAM: Hit! (2.1 points) Character set indicates a foreign language SPAM: Hit! (3.2 points) HTML-only mail, with no text version SPAM: Hit! (1.9 points) Subject is all capitals SPAM: SPAM: -------------------- End of SpamAssassin results --------------------- Now, let's say I'm a foreign language student ... I don't feel it is appropriate for *my* email to have a weight of 2.1 assigned to it due to "Character set indicates a foreign language", so wish to set that to 0.0 instead ... 'HTML-only email', I get quite regularly due to the high number of Outlook users, so let's half its weight to 1.6 ... and I want my threshold to be 7.5 instead of 5 ... so, based on my personal changes, that email would score a 5.6, which means it wouldn't be tagged as spam then ... Now, if you can show me a way to write that with the comparison extensions such that I can sell that to 5k+ students, staff and faculty as being something "even an Outlook user" could write ... I'll be suitably impressed ... Of course, I could do this using the .spamassassin/userprefs configuration file, but this won't work since there is no way for postfix to differentiate users :(