Re: [exim] require in acl EXCEPT for a particular recipient

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Ted Cooper
Date:  
À: exim-users
Sujet: Re: [exim] require in acl EXCEPT for a particular recipient
Marcin Krol wrote:
> Would it be possible to do it using ACL user variables? That is, if

recipient address in some specific ACL is checked as existing in the
/etc/domeny/spamtrap_addresses file, $acl_m_somevariable gets set and
then a router preceding "lookuphost" could be configured that passes the
message on to local delivery depending on $acl_m_somevariable?
>
> Or is there some simpler way to do it?


To collect everything that gets sent to my spamtraps, I put a lot of
short cuts at the top of ACLs and use ACL variables to pass on that state.

Any message sent to a spamtrap will be fakerejected (you can just drop
the control=fakereject to stop that).
The sender address isn't checked unless you put this after sender
address checking :P I have it very near the top of the ACL after a few
minor sanity/flooding/alert checks.

I'm pretty sure this is actually what you're after but it's late and I'm
tired. Hopefully it helps even if I'm completely off the mark.

The spamtrap collection (obfuscated cos I made it up!)
/etc/exim/bwlists/spamtraps
example.com:    address1:adderss2:address3
example2.com:    address4:address5


Near the top of my RCPT ACL (after some checks)
  accept  domains       = +local_domains
          recipients    = @@lsearch;/etc/exim/bwlists/spamtraps
          log_message   = Message sent to spam trap ($local_part@$domain)
          message       =
          set acl_c0    = spamtrap
          control       = fakereject/MSG_THANKSPAM


Routers:
spamtraps:
  driver        = accept
  condition     = ${if eq{$acl_c0}{spamtrap}{1}{0}}
  transport     = spamtrap


Transports:
spamtrap:
driver = appendfile
directory = /home/spamc/SPAMTRAP
maildir_tag = ,S=$message_size
maildir_format
delivery_date_add
envelope_to_add
return_path_add
create_directory
user = spamc


No idea if this what you're actually after but it looks along the right
lines :P


--
The Exim Manual
http://www.exim.org/docs.html
http://www.exim.org/exim-html-current/doc/html/spec_html/index.html