On 2011-08-05 16:22, Magnus Bäck wrote:
On Tuesday, August 02, 2011 at 19:25 CEST,
      Jeroen Geilman<jer...@adaptr.nl>  wrote:

On 2011-08-02 06:30, Noel Butler wrote:

Has been a while since I've looked at this, but at present if we
need to alias a domain, eg f...@example.com to f...@example.net
we are using  mysql:/etc/postfix/mysql_alias_domains.cf after
other entries in  our virtual_alias_maps
and using
query = SELECT email from virtual_users where email='%s' OR email =
CONCAT('%u@', (SELECT destination from aliased_domains where
domain = '%d'))
Consider adding a regexp or PCRE map for this:

     virtual_alias_maps = mysql:/etc/postfix/mysql_alias_domains.cf
regexp:/etc/postfix/domain_aliases

/etc/postfix/domain_aliases:

     /^([^@]+)@from_domain$/    $(1)@to_domain

It'll be faster than mysql, too ;)
No, don't do this.

I agree that he probably shouldn't do this in the first place without a valid recipient map, but I was only correcting the mysql fiasco...

  This breaks recipient validation in the same way that

    @from_domain                @to_domain

in an indexed map does, except it's more complicated.

Well, no, not "breaks" - just always passes it.

If you know why you're doing it, and will absolutely never send backscatter because of it, it's possible to do so.


--
J.

Reply via email to