procmail
[Top] [All Lists]

Re: An 'or' recipe

2017-08-14 02:01:29
On 13.08.17 16:20, John Conover wrote:
#
ws='[    ]*($[   ]+)*'
#
:0
* 2147483647^0 $ ^From:${ws}.*susanmay21@iinet\.net\.au
* 2147483647^0 $ ^From:${ws}.*billh@marsjourney\.info   
* 2147483647^0 $ ^From:${ws}.*mail@cchaseharwood\.com
* 2147483647^0 $ ^From:${ws}.*barry@barryjhutchison\.com
    .
    .
    .
* 2147483647^0 $ ^From:${ws}.*jrobertsonwrites@gmail\.com
$AUTHORS

To increase readability, and remind that the maximal scoring value is
there merely to provide OR functionality, I tend to use either:

OR=2147483647^0        # Max score => immediate success. i.e. OR

   :0
   * $ $OR ^From.*@amazon.com
   * $ $OR ^From.*@crosswalkmail.com
   * $ $OR ^From.*@denali.com
   * $ $OR ^From.*Design_News_Surveys
   * $ $OR ^From.*dnonline(_at_)email(_dot_)designnews(_dot_)com
   * $ $OR ^From.*DM2Decisionmaker.com
   * $ $OR ^From.*@Eng-Tips.com
   * $ $OR ^From.*facebook
   * $ $OR ^From.*@standard.com.au
   * $ $OR ^From.*newfrog
   spam

Or a combination of Oring methods, which works well when the cases to
cover are not always simply OR.

   :0 HB:                              # Head/Body parasites, including
                                       # Korean gibberish spam.-
   * $ $OR charset(.*ks_c_5601-1987|="?euc-kr|="?gb2312)
   * $ $OR "((Almighty|spirit of) God)|(God fearing)"
   * $ $OR (You have won|Airego|SpaceClaim)
   * $ $OR ^From.*noreply(_at_)googlegroups(_dot_)com
   * $ $OR ^From.*@boxbe.com
   * $ $OR ^From.*@autopartssupply.com.au
   * $ $OR (((easy|more) money)|((a|the|that|our) degree))
   * $ $OR 
(geschenkt|verlieren|abgesichert|gewinn|verdien|kosten(los|frei)|lizenz|mitglied|teilnehmer)
   * $ $OR X-IronPort-SPAM: SPAM
   * ! List-Id: Discussions about the AVR-GCC toolchain
   spam

That has for half a decade or more been sufficient spam deflection,
until I subscribed to the debian users list. They haven't bothered to
spam filter their list (last spam haven on the planet, perhaps) so now
there's 2 or 3 spams per day - I haven't seen so many in years.

Erik
____________________________________________________________
procmail mailing list   Procmail homepage: http://www.procmail.org/
procmail(_at_)lists(_dot_)rwth-aachen(_dot_)de
https://mailman.rwth-aachen.de/mailman/listinfo/procmail

<Prev in Thread] Current Thread [Next in Thread>