Re: [AMaViS-user] Amavis + Postfix

This is a discussion on Re: [AMaViS-user] Amavis + Postfix within the Amavis User forums, part of the Anti-Spam and Anti-Virus Related Forums category; Colin Viebrock wrote: > On 29-Apr-07, at 7:41 AM, mouss wrote: > > >>> Some ...


Go Back   Usenet Forums > Anti-Spam and Anti-Virus Related Forums > Amavis User

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-30-2007
mouss
 
Posts: n/a
Default Re: [AMaViS-user] Amavis + Postfix

Colin Viebrock wrote:
> On 29-Apr-07, at 7:41 AM, mouss wrote:
>
>
>>> Some of the aliases in the MySQL table are wildcards, yes.
>>>
>>> I suppose the "right way" to handle this would be to duplicate all
>>> the "domain1.tld" aliases as "domain2.tld", instead of wildcards?
>>>
>>>

>> yes. with mysql, you can avoid duplication if you only have "1
>> recursion depth" aliases (or 2. but high recursion depths
>> complicate the
>> query). make the query return a value only if the target address
>> exists.
>>

>
> Actually I just checked, since I'm using PostfixAdmin to manage
> theses virtual domain aliases. The table has entries like:
>
> +---------------------+-------------------+
> | address | goto |
> +---------------------+-------------------+
> | @anewpark.org | @anewpark.ca |
> | @anewpark.net | @anewpark.ca |
> | @anewpark.com | @anewpark.ca |
> +---------------------+-------------------+
>
> I suppose these would still be considered "wildcards", even though
> they don't have asterisks?
>


yes, they are. and this is horrible because you don't need such things
in mysql. the general rule is: if you put structure in your fields, then
you misdesigned your tables.


alias domains can be implemented with "simple" (not composite) field
like this:

query = select concat (user, '@', domain) from User, Alias_Domain where
user = '%u'
and
domain = target_domaina
and
alias_domain = '%d'

with a User table that contains {user, domain} fields (you can add more
and adjust the query above) and an Alias_Domain table that contains
{alias_domain, target_domain} fields. you can of course have a Domain
table with many fields if you prefer...



-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
AMaViS-user mailing list
AMaViS-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/...fo/amavis-user
AMaViS-FAQ:http://www.amavis.org/amavis-faq.php3
AMaViS-HowTos:http://www.amavis.org/howto/
Reply With Quote
Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 10:34 AM.


Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0