[Gllug] How to get exim4 to use different relays depending on target address

John Winters john at sinodun.org.uk
Sat Sep 17 15:36:08 UTC 2005


I'm looking for some assistance with exim4 configuration on a pretty
vanilla Debian Sarge box.

This box is at school and I want to be able to send outgoing e-mail from
it.  Unfortunately the e-mail setup at school is slightly odd.

I can't send e-mail directly to the outside world because port 25 will
be blocked by the firewall.

I can connect to our own internal SMTP server (which handles most of our
outgoing e-mail) but the admins controlling it won't let me use it as a
relay.  I can thus use it only for local e-mail - that intended for
someone within the organisation.

For external e-mail I can use one external SMTP server (the one which
handles our incoming e-mail), but if I send internal e-mail to that
machine it is then passed through a (really crap) spam filter which
flags a significant amount of my internal e-mail as spam.  It's so crap
that it doesn't even give a reason, so I've no way of knowing what I
need to do to get it to stop.  Support's view is that it's expensive so
it must be good and getting it fixed is probably not an option.

So, what I need to do is arrange that mail passing through exim4 on my
box is routed to one of two different places:

    If it is for <anyone>@<ourorganisation>.co.uk then it needs to go
    to the internal SMTP server.

    Otherwise it needs to go to the external SMTP server.

In other words, I want to configure exim4 to use a smarthost for most
purposes, but for one particular set of addresses it is to use a
different relay.

Is there a simple way of doing this please?

Regards,
John

-- 
Gllug mailing list  -  Gllug at gllug.org.uk
http://lists.gllug.org.uk/mailman/listinfo/gllug




More information about the GLLUG mailing list