[Exim] Exim 4 greylisting solution: greylistd

Αρχική Σελίδα
Delete this message
Reply to this message
Συντάκτης: Tor Slettnes
Ημερομηνία:  
Προς: Exim Users
Αντικείμενο: [Exim] Exim 4 greylisting solution: greylistd
Hello,

For those interested, I have submitted to the Debian project a small
greylisting daemon for use primarily with Exim 4 (though it can probably
be used for other MTAs as well).  It is available (.deb and .tar.gz) at:
    http://packages.debian.org/unstable/mail/greylistd


It is written in python, and is completely standalone (i.e. it does not
depend on the installation of a database engine). Greylist triplets are
maintained and stored into its own data file as 32-bit hash values. It
supports a "stats" command to obtain greylisting statistics.

It does not require any particular feature or patch to Exim itself;
instead, it would be invoked by way of a ${readsocket ..} or ${run ..}
expansion in an Exim ACL (preferrably after RCPT TO:). For instance:


  # If the remote host is in a whitelist, accept the RCPT TO: command.
  #
  accept
    condition   = ${if exists {/etc/mail/whitelist-hosts} {true} {false}}
    hosts       = /etc/mail/whitelist-hosts



  # Accept mail from a null sender, because these are supposed to be
  # administrative mails (delivery notifications, sender verifications...)
  #
  accept
    senders     = :



  # For regular messages, consult "greylistd" to obtain greylisting status
  # for this particular host/sender/recipient triplet.
  #
  defer
    message     = $sender_host_address is not yet authorized to deliver \
                  mail from <$sender_address> to <$local_part@$domain>. \
                  Please try again later.
    log_message = greylisted.
    set acl_m9  = $sender_host_address $sender_address $local_part@$domain
    set acl_m9  = ${readsocket{/var/run/greylistd/socket}{$acl_m9}}
    condition   = ${if eq {$acl_m9}{grey}{true}{false}}
    delay       = 20s




Best,
-tor