Re: [EXIM] exim, subdomains, qualify_domain and majordomo

Página Principal
Apagar esta mensagem
Responder a esta mensagem
Autor: Marc Haber
Data:  
Para: exim-users
Assunto: Re: [EXIM] exim, subdomains, qualify_domain and majordomo
On Tue, 7 Jul 1998 12:10:23 +0100 (BST), you wrote:
>I can understand that, though the specific alias file can't come out of
>the box, can it? Getting people to use fully qualified addresses all the
>time would be a Good Thing.


I second this, giving my recent experiences.

>It should do. However, I don't think that rule is safe. If another host
>sent a message to *@mydomain.de and happened to send "majordomo" as the
>RFC 1413 identification string, the rule would trigger. It might be
>better to test for $sender_address being majordomo@???,
>or possibly to test for *both* conditions.


That actually definetely won't work since the messages are sent by
owner-{listname}@??? by majordomo configuration.

>
>Or, alternatively, you could test for $sender_host_address being empty,
>indicating a locally submitted message, and then check the ident.


I did some experiments today and in fact have found out several
possible solutions:

(1)
|*@mydomain.de   "${if eq{$sender_address}{owner-test-list@???} \
|    {$1@???} \
|    fail}"


This rewrites @mydomain.de with @lists.mydomain.de iff the mail is
sent by owner-test-list@???. I would have to have a
pattern match there to match owner-.*@??? here.


(2)
|*@mydomain.de "${if and{eq{$sender_host_address}{}} \
|            {eq{$sender_ident}{majordomo}}} \
|            {$1@???} \
|            fail}"


This rewrites iff the mail was delivered by a direct exim call on the
local host and the ident of the sender is majordomo. This should work
reasonably well.

(3)
|*@mydomain.de "${if eq{$received_protocol}{majordomo} \
|            {$1@???} \
|            fail}"


This relies on exim being called from majordomo with -oMr majordomo,
which can be accomplished via setting $mailer in majordomo.cf. Also,
this works reasonably well.

However, this approach poses another serious problem. Assume that an
mh@??? is subscribed to test-list@???.
A mail for test-list@??? comes in. The mail gets piped
through majordomo by the majordomo alias file. Majordomo resends that
mail to test-list-outgoing. test-list-outgoing is qualified to
test-list-outgoing@??? by qualify_domain.

The rewrite rule triggers, rewriting test-list-outgoing@??? to
test-list-outgoing@???. This expands to the list of
recipients by means of the majordomo alias file.

One of these recipients is mh@???. The rewrite rule triggers,
rewriting mh@??? to mh@???. Delivering that mail
fails since there is no entry for mh@??? in the
majordomo alias file. The system alias file does not apply to
lists.mydomain.de.

I am currently thinking of setting qualify_domain to something like
foo.mydomain.de and rewriting that foo.mydomain.de either to
mydomain.de or lists.mydomain.de by a rewrite rule above. This looks
like a bad fix and I would prefer to have a chance to identify an
address that has been qualified by qualify_domain.

Am I missing something here?

Greetings
Marc

-- 
-------------------------------------- !! No courtesy copies, please !! -----
Marc Haber          |   " Questions are the         | Mailadresse im Header
Karlsruhe, Germany  |     Beginning of Wisdom "     | Fon: *49 721 966 32 15
Nordisch by Nature  | Lt. Worf, TNG "Rightful Heir" | Fax: *49 721 966 31 29



--
*** Exim information can be found at http://www.exim.org/ ***