Re: [exim] Weird domain matching

Etusivu
Poista viesti
Vastaa
Lähettäjä: Dave Evans
Päiväys:  
Vastaanottaja: Peter Thomassen
Kopio: exim-users
Aihe: Re: [exim] Weird domain matching
On Mon, Mar 28, 2011 at 12:04:02AM -0400, Peter Thomassen wrote:
> Hi,
>
> I was testing around with exim4 -d -bh, sending an e-mail from some
> @physik.uni-wuerzburg.de address to myself. I coincidentally saw the
> following debugging output:
>
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
>> Verifying <...>@physik.uni-wuerzburg.de
>> address match: subject=<...>@physik.uni-wuerzburg.de pattern=*@+local_domains
>> search_open: mysql "NULL"
>> cached open
>> search_find: file="NULL"
>> key="SELECT DISTINCT full_domain FROM mail_alias WHERE full_domain='peter-thomassen.de'" partial=-1 affix=NULL starflags=0
>> LRU list:
>> :/etc/exim4/tap
>> :/etc/aliases
>> End
>> internal_search_find: file="NULL"
>> type=mysql key="SELECT DISTINCT full_domain FROM mail_alias WHERE full_domain='peter-thomassen.de'"
>> cached data used for lookup of SELECT DISTINCT full_domain FROM mail_alias WHERE full_domain='peter-thomassen.de'
>> lookup yielded: peter-thomassen.de
>> physik.uni-wuerzburg.de in "@:localhost:localhost.a4a.de:a4a.de:mail.a4a.de:mysql;SELECT DISTINCT full_domain FROM mail_alias WHERE full_domain='peter-thomassen.de'"? yes (matched "mysql;SELECT DISTINCT full_domain FROM mail_alias WHERE full_domain='peter-thomassen.de'")
>> physik.uni-wuerzburg.de in "+local_domains"? yes (matched "+local_domains")
>> <...>physik.uni-wuerzburg.de in "*@+local_domains"? yes (matched "*@+local_domains")
>
> I inserted the <...>.
>
> When verifying the sender <...>@physik.uni-wuerzburg.de, I think this
> domain should be injected in the SQL statement, not peter-thomassen.de
> (which was the recipients' domain).


$domain means different things in different contexts. Sometimes it's the
sender's domain, sometimes it's that of the recipient. It all depends on your
config, which of course we don't yet know. For example, you tell us how
MAIN_LOCAL_DOMAINS is defined, but you don't tell us why you think that's
relevant, e.g. where it's used.

If you need a more concrete explanation, I think you'll need to show us rather
more of your config.

--
Dave Evans
http://djce.org.uk/
http://djce.org.uk/pgpkey