Re: [Exim] filtering with virtual mailboxes

Startseite
Nachricht löschen
Nachricht beantworten
Autor: Nico Erfurth
Datum:  
To: Spaced, Exim-Users (E-mail)
Betreff: Re: [Exim] filtering with virtual mailboxes
Spaced wrote:
> Hello
>
> I'm using Exim4 with courier-imap / pop, and mysql to set up virutal
> mailboxes for a few domains I host.
>
> For local address', I have mail filtering enabled through .forward .. sorts
> mail from various lists into appropriate folders, etc.
>
> For virtual mailboxes, I have no idea how I can achieve the same
> functionality....
>
> Is it asking the impossible to be able to have the filter rules stored in
> the DB somewhere?


No, you aren't.

virtual_filter:
   driver = redirect
   data = ${lookup mysql {select filter from table where \
          user='$local_part@$domain'}}
   router_home_directory = THE_USERS_MAILDIR
   user = some unprivileged user
   ....


The data returned from the lookup MUST look like a normal exim filter file.

Nico