On Sun, 25 Jan 2009 23:58:36 mouss wrote:
> James Robertson a écrit :
> > Hi,
> >
> > If I have:
> >
> > relay_recipient_maps = hash:/etc/postfix/recipients
> >
> > which is populated with addresses accepted for delivery on my server and
> > have:
> >
> > smtpd_recipient_restrictions = reject_unlisted_recipient,
> >
> > Can I safely set:
> >
> > relay_domains = *
>
> do you mean
> relay_domains = static:all
> ?
>
> why would you do that? I mean what is the (real, business) problem you
> are trying to solve?
>
> since you update the list of recipients, you can also update the list of
> relay domains, with something like:
>
> sed 's/^...@]*@/@/' relay_recipients |sort|uniq > relay_domains

Sorry for the bad initial question.  *cringes*

I am using the getadsmtp.pl script to pull addresses from an exchange server 
to a box that does spam filtering on the inbound mail (no mail is delivered 
locally to the antipspam box).  when we have to add domains to the Exchange 
Server we have also been adding them to relay_domains and transport in 
postfix on the antispam box.

We just run the getadsmtp.pl script every hour on the hour to grab any 
addresses that may have been added or removed from the domain/s.

the main issue is that we have quite a few of these postfix antispam boxes 
installed at clients sites now and not alot of Linux/Postfix able technicians 
to make changes to them, so if a domain is added and a Windows tech forgets 
to advise us or no-one is available to configure it, mail won't deliver to 
the domain.

Basically i'm wanting to automate the addition of new domains  (in 
relay_domains and transport) when they get added in Exchange somehow, and 
thought that if mail is rejected if a recipient address was not 
in /etc/postfix/recipients, then allowing everything in relay_domains would 
not be a problem.

What you provided above has got me pointing in the right direction though, so 
if any other ideas might help me I would appreciate it.

just in case you are not aware of the getadsmtp.pl script the link to it is 
here http://www-personal.umich.edu/~malth/gaptuning/postfix/getadsmtp.pl

You might be wondering why I didn't mention transport previously.... I was 
just going to deal with one thing at a time.

Thanks, and I will avoid being a blacklisted open relay.... :)

James

Reply via email to