[Exim] How to distinguish between mail to be relayed and loc…

Página Principal
Apagar esta mensagem
Responder a esta mensagem
Autor: Eli
Data:  
Para: exim-users
Assunto: [Exim] How to distinguish between mail to be relayed and locally delivered email in ACLs?
I just realized after setting up exiscan to scan emails for spam, that I
would be scanning both emails that my users are sending out to remote hosts,
and also emails that are to be accepted locally. Now, there's nothing
really wrong with that, except that I would like to have emails scanned only
if they are being sent to a local address (ie, not a user sending outbound
email).

I figured that'd be simple enough with just checking the authenticated
setting since all my users musth auth - except then I remembered that
there's my relay_to_domains and relay_from_hosts lists which (although
currently empty) may contain other users which I may not want to scan email
for either if it's to be relayed out.

Is there any sure-fire way to (in a DATA ACL) tell if a message is locally
or remotely bound? I thought of testing domains or recipient or something,
but I believe those are valid only during the RCPT ACL?

It would be nicer if emails were spam-scanned before being sent out, but
even if they are nobody would trust my settings anyways and would always
want to re-scan it, so I figure why waste my CPU time scanning it when it
will be scanned again anyways :P (but that's not a discussion for now - I'm
more interested in *how* to do what I described, not whether it's good
practice or not :))

Thanks in advance,

Eli.

---
[This E-mail scanned for viruses]