Re: [exim] Exim smarthost condition

Kezdőlap
Üzenet törlése
Válasz az üzenetre
Szerző: Sander Smeenk
Dátum:  
Címzett: exim-users
Tárgy: Re: [exim] Exim smarthost condition
Quoting Sysadmin (eduardo.silvestre@???):

> Any clue about this?


Relaying is usually controlled in the RCPT ACL. In a default setup it
usually already has some configuration along the lines of:

accept hosts = +relay_from_hosts

Just before that you could create a new 'accept' statement which has a
'condition =' test in which you can expand, lookup and compare certain
values. If the condition is true, the message is accepted.
Earlier tests in the RCPT ACL should ensure your system is capable of
routing the message onward (see 'require verify = recipient').

This all is explained thoroughly in The Fine Documentation:

About ACLs in a more general form: https://8n1.org/9153/8924

About 'lists' of hosts, domains and lookups on them:
https://8n1.org/9155/dfbf

And about string expansion: https://8n1.org/9154/22d3 which you'd have
to use in your 'condition ='-test. Please note this URL also lists the
available functions and operators which would aid you in your quest.

Word of warning: test your conditions thoroughly or you might open your
servers to relaying for unwelcome sources. You can test your conditions
by using 'warn' instead of accept:

  warn log_message = Debugoutput
       condition = ..


Also, people tend to forget how usefull 'exim4 -bh $ipaddress' is.

HTH,
-Sndr.
--
| No, i'm not writing it for you. :)
| 4096R/20CC6CD2 - 6D40 1A20 B9AA 87D4 84C7 FBD6 F3A9 9442 20CC 6CD2