[Pkg-exim4-users] Catch all mailbox

Martin D Fraser mdf@darksnow.net
Tue, 12 Apr 2005 10:11:26 +0100


On Tue, Apr 12, 2005 at 08:32:50AM +0200, Marc Haber wrote:
> Hi Martin,
> 
> can you please subscribe to the list with the address you are posting
>
Sorry about that. I had changed some mail client settings for testing. 
This one should come from the right place.
> 
> Can you document this in exim -bt output? I do not quite understand
> what you mean.
> 
The -bt output is very large, as I'm sure you know. It boils down the 
fact that I have there entries in my alises file:

postmaster: root
root: mdf
*: postmaster

An email sent to testaddress@mydomain caused it to say:
Considering testaddress -> matched postmaster (the catchall)
Considering postmaster  -> matched root
Considering root	-> matched mdf (a real user name)
Considering mdf		-> matched postmaster
Considering postmaster	-> already matched, routing fails at this point

> There is a pitfall with catchall accounts: The catchall target will
> re-trigger the catchall. This can be remedied by aliasing the target
> to itself, like in:
> 
> catchall_target: catchall_target
> *: catchall_target
> 
So if I alias postmaster: postmaster and move the routers back to the 
correct order it will eventually match my real username, or should I add 
an alias for the real username i.e. mdf: mdf

> This will prevent the catchall to trigger again on the second round.
> 
> btw, I consider having catchalls as a very bad idea in this time.
> 
I understand the problems and appreciate the concern, but I find it 
handy to subscribe to things using a throw away address. I could 
subscribe to this list with exim@mydomain and if I get spam on that 
address I know where they got my address.

> > So, I dug further and found that the real_user router appears to match 
> > real user names prepended with the word real-,
> 
> Yes. This avoids forward and alias processing for real-user, which can
> be used to reach users who have broken their forwarding process by
> using an illegal .forward file. See th userforward router for
> examples. I have also put some documentation in the real_local router
> file.
> 
Ok. So by moving the local_user router as I have done, the .forward 
router will never process the file. I really have broken my setup and 
I'll put it all back :) I thought the maintainer of an email package 
would know a lot more about this that I do. Thanks for the explaination.

> Explained above. Or should I elaborate more?
> 
That makes perfect sense now. If I had a problem sending to mdf because 
that user had broken the .forward file, I could send to real-mdf and 
skip all the clever processing. Is that right?

> > Secondly, what was the reason for putting the local_user router after 
> > the system_alises router.
> 
> To allow local user names to be overriden by aliasing. For example, I
> do not want my local daemon user to receive mail. So, I alias it to
> root in /etc/aliases, which prevents the local_user router from being
> accessed for the local user daemon at all.
> 
So, actual local users can have their mail sent to another local user 
simply by sticking an alias in the file. Of course. Silly me.

> > It seems to me that this may be a mistake 
> 
> No, it's a feature.
> 
Yup. Good feature to, sorry I doubted you.

> > since my problem must happen to anyone with a wildcard in the aliases 
> > file.
> 
> Wildcards are a bad idea anyway.
> 
Yup, they can be, but I find it handy to get mail for typos as well. If 
somebody mistyped my address I could bounce the mail, but if it was my 
mum for example, she would be confused by the bouce ;)

> > I understand that I added the lsearch* to the router and therefore 
> > caused the loop myself, but why in the world would it be set to check 
> > the system_aliases before checking against the list of actual user accounts.
> 
> That is a good idea. Or do you want to receive mail for "bin"?
> 
Yup, perfect.

> Greetings
> Marc
> 
Cheers Marc. A good reply as usual. That seems to have answered all my 
questions and will allow me to sort out my mail setup properly while 
still allowing my ill advised wildcard address.

Cheers again and sorry about the post from the wrong address.

Martin...