Andy,

Taking your original filter, this is what you would do (note the NOTCONTAINS line in the second filter):

   # ADD-WEIGHT
   TESTSFAILED 7 CONTAINS SNIFFER
   TESTSFAILED 1 CONTAINS SNIFFER-SCAMS
   TESTSFAILED 1 CONTAINS SNIFFER-PORN
   TESTSFAILED 2 CONTAINS SNIFFER-MALWARE
   TESTSFAILED 1 CONTAINS SNIFFER-OBFUSC
   TESTSFAILED -2 CONTAINS SNIFFER-IP
TESTSFAILED 4 CONTAINS INV-URIBL-WT1
   TESTSFAILED 5 CONTAINS INV-URIBL-WT2
   TESTSFAILED 6 CONTAINS INV-URIBL-WT3
   TESTSFAILED 7 CONTAINS INV-URIBL-WT4
-----

   # EXTRA-WEIGHT
   TESTSFAILED END NOTCONTAINS ADD-WEIGHT

   TESTSFAILED END CONTAINS SPAMCOP
   TESTSFAILED END CONTAINS NJABLSOURCES
   TESTSFAILED END CONTAINS AHBLSOURCES
   TESTSFAILED END CONTAINS AHBLPSSL
   TESTSFAILED END CONTAINS SORBS-SPAM
   TESTSFAILED END CONTAINS SENDERDB-BLOCK
   TESTSFAILED END CONTAINS SBL
TESTSFAILED 2 CONTAINS SNIFFER-IP

In your Global.cfg, you would only need to make sure that ADD-WEIGHT appear before EXTRA-WEIGHT.

Matt





Andy Schmidt wrote:
I'm familiar with MAXWEIGHT and I'm using it.
It doesn't address this particular application. Best Regards
*/Andy Schmidt/*/
/
Phone:  +1 201 934-3414 x20 (Business)
Fax:    +1 201 934-9206

    -----Original Message-----
    *From:* [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] *On
    Behalf Of *John T (Lists)
    *Sent:* Friday, November 17, 2006 05:52 PM
    *To:* declude.junkmail@declude.com
    *Subject:* RE: [Declude.JunkMail] Filter 'END' statement in 4.3.14
    flushes WEIGHT?

    OK, I understand that better but you will always be better off
    grouping each intent into a different combo filter. Then, you can
    even have a combo filter dependent upon another combo filter by
    why of order of list and including the name of the combo filter as
    an IF statement in the next one.

    Combo filters need to be viewed as a different type of test rather
    than a normal filter test. If you write down in groups want you
    want to do, it will be easy to then create them.

    Say if you want to add 12 if 4 or more rbl tests failed. You would
    create a combo filter like this:

    MINWEIGHTTOFAIL    12

    MAXWEIGHT            12

    TESTSFAILED 3        CONTAINS     rbl1

    TESTSFAILED 3        CONTAINS     rbl2

    TESTSFAILED 3        CONTAINS     rbl3

    TESTSFAILED 3        CONTAINS     rbl4

    TESTSFAILED 3        CONTAINS     rbl5

    TESTSFAILED 3        CONTAINS     rbl6

    TESTSFAILED 3        CONTAINS     rbl7

    TESTSFAILED 3        CONTAINS     rbl8

    That way, at least 4 have to hit to equal 12 before it will see
    this test as failing, but it will only add 12 and not more.

    **John T**

    **eServices For You**

****
    *"Life is a succession of lessons which must be lived to be
    understood."*

    *Ralph Waldo Emerson (1802-1882)*

**
    -----Original Message-----
    *From:* [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] *On
    Behalf Of *Andy Schmidt
    *Sent:* Friday, November 17, 2006 2:13 PM
    *To:* declude.junkmail@declude.com
    *Subject:* RE: [Declude.JunkMail] Filter 'END' statement in 4.3.14
    flushes WEIGHT?

    Hi John:

    >> What is the logic of the second part anyways, to add weight for
    test4 and test5 IF test1 and test2 failed? <<

    If you have several blacklists of the same family (e.g., multiple
    open-relay filters, or multiple open-proxy filters) I like to
    group them together.  I give a big weight to the entire group (the
    filter itself) and then may add an increment for blacklists with
    few false positives (each "contains" clause).

    Simiarly with Sniffer or invURIBL.  There is some overlap between
    those two, and there is a potential overlap between Sniffer-IP and
    blacklists of "recent spam sources" (e.g., SpamCop, MXRate-Block).

    I have a filter that processes my various Sniffer types and
    invURIBL returns. At some point, I'd like to stop and first look
    if certain other Blacklist Tests had fired. If so, I'm done.  If
    not, I want to add a little extra for Sniffer-IP.

    Best Regards
    */Andy Schmidt/*/
    /
    Phone:  +1 201 934-3414 x20 (Business)
    Fax:    +1 201 934-9206

    ------------------------------------------------------------------------

    *From:* [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] *On
    Behalf Of *John T (Lists)
    *Sent:* Friday, November 17, 2006 02:41 PM
    *To:* declude.junkmail@declude.com
    *Subject:* RE: [Declude.JunkMail] Filter 'END' statement in 4.3.14
    flushes WEIGHT?

    Any filter that I do not have as active is moved to
    \declude\filters\notused from \declude\filtes so that my filters
    folder only contains filters that I am currently using.

    In your example, you are putting the IF statement after the THEN
    statement. I am not a programmer, but IF (the test of what you
    want to be quantified) always comes before THEN (the result you
    want to occur depending upon whether the test of the
    quantification failed or passed, meaning did it meat the criteria
    which is the defined IF statement), so the first part of your
    example does not make any sense. You only want weight added if
    test3 failed, so you have to quantify that FIRST and then say what
    occurs by adding weight.

    So, you have to have to filters since both sections rely upon
    testing IF test3 has failed or not.

    What is the logic of the second part anyways, to add weight for
    test4 and test5 IF test1 and test2 failed?

    **John T**

    **eServices For You**

    *"Life is a succession of lessons which must be lived to be
    understood."*

    *Ralph Waldo Emerson (1802-1882)*

    -----Original Message-----
    *From:* [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] *On
    Behalf Of *Andy Schmidt
    *Sent:* Friday, November 17, 2006 10:48 AM
    *To:* declude.junkmail@declude.com
    *Subject:* RE: [Declude.JunkMail] Filter 'END' statement in 4.3.14
    flushes WEIGHT?

    >> Why the requirement of single filter? <<

    Clarity? It's easier for me to follow a logic, if it's enclosed in
    a SINGLE source document (= filter).

    If the logical is spread over multiple source documents, I have to
    first scour the Global.CFG to see which filters are active,
    then inspect each one to see if by chance any one of them might
    have any effect.

    Best Regards
    */Andy Schmidt/*/
    /
    Phone:  +1 201 934-3414 x20 (Business)
    Fax:    +1 201 934-9206

    ------------------------------------------------------------------------

    *From:* [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] *On
    Behalf Of *John T (Lists)
    *Sent:* Friday, November 17, 2006 12:57 PM
    *To:* declude.junkmail@declude.com
    *Subject:* RE: [Declude.JunkMail] Filter 'END' statement in 4.3.14
    flushes WEIGHT?

    Why the requirement of single filter?

    I have different combo filters created like this:

    ComboFilterA

    REM If testa and testb fail, and if testc or testd fail, add 10

    ENDONFIRSTHIT

    TESTSFAILED END NOTCONTAINS testa

    TESTSFAILED END NOTCONTAINS testb

    TESTSFAILED 10 CONTAINS testc

    TESTSFAILED 10 CONTAINS testd

    ComboFilterB

    REM If testc and testd fail, and if teste or testf fail, add 20

    ENDONFIRSTHIT

    TESTSFAILED END NOTCONTAINS testc

    TESTSFAILED END NOTCONTAINS testd

    TESTSFAILED 10 CONTAINS teste

    TESTSFAILED 10 CONTAINS testf

    IMHO, that is a much cleaner and neater way to do it. You could
    also use MAXWEIGHT instead of ENDONFIRSTHIT and then assign
    different weights to different test.

    **John T**

    **eServices For You**

    *"Life is a succession of lessons which must be lived to be
    understood."*

    *Ralph Waldo Emerson (1802-1882)*

    -----Original Message-----
    *From:* [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] *On
    Behalf Of *Andy Schmidt
    *Sent:* Friday, November 17, 2006 9:29 AM
    *To:* declude.junkmail@declude.com
    *Subject:* RE: [Declude.JunkMail] Filter 'END' statement in 4.3.14
    flushes WEIGHT?

    Hi John,

    >> Was never changed. <<

    Please read the URL I posted:

    http://www.mail-archive.com/declude.junkmail@declude.com/msg14009.html

    As you can tell, ORIGINALLY it did return the weight. He was
    thinking of it even FAILING the test (if there was a weight).

    >> What you should have been using is MAXWEIGHT at the top, or
    STOPATFIRSTHIT. <<

    Kindly, please read the sample I had posted (bottom of this
    message). Your reply doesn't address the issue of trying to make
    some sections of a test conditional. Example, the goal is to
    return either 1 or 2 or 3 if test1 or test2 occur with test3 - and
    to only add test4 and test5, if test3 is not true.

        SKIPIFWEIGHT 20

        MAXWEIGHT 3

        TESTSFAILED 1 CONTAINS test1
        TESTSFAILED 1 CONTAINS test2

        TESTSFAILED END CONTAINS test3

        TESTSFAILED 1 CONTAINS test4

        TESTSFAILED 1 CONTAINS test5

        etc etc

    Please demonstrate how MAXWEIGHT or STOPATFIRSTHIT would do this
    in a single filter?

    Best Regards
    */Andy Schmidt/*/
    /
    Phone:  +1 201 934-3414 x20 (Business)
    Fax:    +1 201 934-9206


    ---
    This E-mail came from the Declude.JunkMail mailing list. To
    unsubscribe, just send an E-mail to [EMAIL PROTECTED], and
    type "unsubscribe Declude.JunkMail". The archives can be found
    at http://www.mail-archive.com.
    ---
    This E-mail came from the Declude.JunkMail mailing list. To
    unsubscribe, just send an E-mail to [EMAIL PROTECTED], and
    type "unsubscribe Declude.JunkMail". The archives can be found
    at http://www.mail-archive.com.


    ---
    This E-mail came from the Declude.JunkMail mailing list. To
    unsubscribe, just send an E-mail to [EMAIL PROTECTED], and
    type "unsubscribe Declude.JunkMail". The archives can be found
    at http://www.mail-archive.com.
    ---
    This E-mail came from the Declude.JunkMail mailing list. To
    unsubscribe, just send an E-mail to [EMAIL PROTECTED], and
    type "unsubscribe Declude.JunkMail". The archives can be found
at http://www.mail-archive.com.

---
This E-mail came from the Declude.JunkMail mailing list. To
unsubscribe, just send an E-mail to [EMAIL PROTECTED], and
type "unsubscribe Declude.JunkMail". The archives can be found
at http://www.mail-archive.com.


---
This E-mail came from the Declude.JunkMail mailing list.  To
unsubscribe, just send an E-mail to [EMAIL PROTECTED], and
type "unsubscribe Declude.JunkMail".  The archives can be found
at http://www.mail-archive.com.

Reply via email to