Wildcard for domain instead of user?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Wildcard for domain instead of user?

Jeff Weinberger-4
I don't know if this is possible in a virtual alias (or even virtual) set up, but I would like to be able to set up a user name with a wildcard domain. Here's what I mean: I host several domains. I would like the address [hidden email]' to go to the same place (me). So my initial thought was to set up in my virtual alias table an entry like this: postmaster@* [hidden email] I use MySQL lookup tables. Will this work? is there a different way to specify the wildcard? is there a different approach I should take to making this work? Any help is much appreciated!

Reply | Threaded
Open this post in threaded view
|

Re: Wildcard for domain instead of user?

Wietse Venema
Jeff Weinberger:
> I don't know if this is possible in a virtual alias (or even virtual)  
> set up, but I would like to be able to set up a user name with a  
> wildcard domain. Here's what I mean:
>
> I host several domains. I would like the address '[hidden email]
> ' to go to the same place (me).

Including the mail that your users send to postmasters at REMOTE domains?
You probably should not intercept such mail without explicit permission.

> So my initial thought was to set up in  
> my virtual alias table an entry like this:
>
> postmaster@*  [hidden email]

The expected syntax is explained in the virtual(5) manual page.
Postfix supports regular expression tables for cases where wildcard
support is needed; see pcre_table(5) or regexp_table(5) for more.

        Wietse
Reply | Threaded
Open this post in threaded view
|

Re: Wildcard for domain instead of user?

mouss-2
In reply to this post by Jeff Weinberger-4
Jeff Weinberger wrote:

> I don't know if this is possible in a virtual alias (or even virtual)
> set up, but I would like to be able to set up a user name with a
> wildcard domain. Here's what I mean:
>
> I host several domains. I would like the address
> '[hidden email]' to go to the same place (me). So my initial
> thought was to set up in my virtual alias table an entry like this:
>
> postmaster@*  [hidden email]
>

As Wietse said, do not intercept mail sent to domains you handle.

> I use MySQL lookup tables. Will this work? is there a different way to
> specify the wildcard? is there a different approach I should take to
> making this work?

configure you sql statement to return "[hidden email]" when '%u' is
postmaster and '%d' is one of _your_ domains.