[exim-dev] [Bug 1137] BATV and Greylisting

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Phil Pennock
Date:  
À: exim-dev
Sujet: [exim-dev] [Bug 1137] BATV and Greylisting
------- You are receiving this mail because: -------
You are on the CC list for the bug.

http://bugs.exim.org/show_bug.cgi?id=1137




--- Comment #1 from Phil Pennock <pdp@???> 2011-08-23 04:30:19 ---
This could probably stand to be cleaned up, but it's a straight cut&paste from
my config file of the definition for $acl_m_core_sender, which handles what you
request, and more.


# For the sender address, handle:
#  BATV PRVS: prvs=<ignore>=email
#    ${sg{$sender_address_local_part}{\N^prvs=.+?=([^=]+)$\N}{\$1}}
#  Yahoo Groups: sentto-<ignore-with:->-rcptlocal=rcptdomain@senderdomain
#  nb: rcptdomain can contain hyphen, as can rcptlocal; can fix latter easily
#      and can fix former if restrict to [0-9-]+? but let's keep it generic
#      and accept whitelist-slip-through for varying $foo in $foo-$bar.
#    ${sg{$sender_address_local_part}{\N^sentto-.+?-([^=-]+=[^=]+)$\N}{\$1}}
#  Nanog: LISTNAME-bounces+USERID
#    ${sg{$sender_address_local_part}{\N^([^+]+-bounces)\+.+$\N}{\$1}}
#  Zsh / ezmlm: LISTNAME-return-NNNN-USER=DOMAIN
#   
${sg{$sender_address_local_part}{\N(.+)-return-\d+-([^=-]+=[^=]+)$\N}{\$1-\$2}}
#  Nested substitutions risk dropping too much, and get harder to read
  warn    set acl_m_core_sender = ${if or{\
                {match {$sender_address_local_part}{\N^prvs=.+?=([^=]+)$\N}}\
                {match
{$sender_address_local_part}{\N^sentto-.+?-([^=-]+=[^=]+)$\N}}\
                {match
{$sender_address_local_part}{\N^([^+]+-bounces)\+.+$\N}}\
                {match {$sender_address_local_part}{\N^(.+)-return-\d+-.+$\N}}\
                }{$1}{$sender_address_local_part}}@$sender_address_domain
# SRS: note that there is - and # encoding in SRS; we ignore it, for purposes
of
# canonicalisation.  See http://www.openspf.org/SRS for one spec, but note that
# there are variances.
  warn    condition = ${if match{$sender_address_local_part}{\N^SRS[01]\N}}
          set acl_m_core_sender = ${if match {$sender_address_local_part}\
                {\N^(?i)SRS[01][=+](?:[^=]+=){2}([^=]+)=(.+)$\N}\
                {$2@$1}\
                {$sender_address_local_part@$sender_address_domain}}



--
Configure bugmail: http://bugs.exim.org/userprefs.cgi?tab=email