procmail
[Top] [All Lists]

greylisting

2003-12-02 14:36:04
As a proof-of-concept, I am developing a greylist-model 
with procmail. Here I present the first step, which is 
not very practical but you might want to learn from it.

<quote from man procmailex>
The [...] recipe eliminates duplicate mails. It tells
formail to keep an nKB cache file in which it will store
the Message-IDs of the most recent  mails  you  received.
</quote>

    :0 Whc: msgid.lock # discard duplicates
    | formail -D 16384 msgid_1st.cache

    :0a   # it was a duplicate
    {
      :0Wh:   # test if it was the first re-occurence
      | formail -D 16384 msgid_2nd.cache
      :0:  # if so, then deliver
      $DEFAULT
    }

    :0   # it was a brand new message
    {
      EXITCODE = 75   # temp failure
      :0
      /dev/null
    }

Of course this is still far away from a real greylist- 
setup.

-- 
Affijn, Ruud

_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

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