Gerald Vogt:
> On 13.03.2013 15:22, Wietse Venema wrote:
> > Gerald Vogt:
> >> Any hostname/subdomain under example.com is local. That's what I want to
> >> tell postfix. And that regardless of what comes after the @ but in our
> >> domain, I know all the names which can appear before the @.
> >>
> >> IMHO, that should not require to list all possible server names...
> > 
> > Use a regexp.
> > 
> > /etc/postfix/main.cf:
> >     relay_domains = pcre:/etc/postfix/relay.pcre
> >     relay_recipient_maps = some database...
> > 
> > /etc/postfix/relay.pcre:
> >     /\.example\.com$/       whatever
> 
> 1. As far as I understand the documentation,
>     relay_domains = example.com
> already accepts all mail for subdomains. A regex is not necessary.

Agreed.  The regexp is a tool for more complicated scenarios.

> 2. This still won't help to accept e-mails for users regardless of what
> comes after the @ and reject it if the user does not exist.

To reject non-existent recipients, list the existing ones in
relay_recipient_maps.  If you can't populate that table, use
reject_unverified_recipient with Postfix's verify cache. The cache
will optimize out common lookups, but not dictionary attacks or
backscatter mail.

        Wietse

Reply via email to