[Dovecot] How to disable imap of some user

Pascal Volk user+dovecot at localhost.localdomain.org
Sat Feb 19 10:17:16 EET 2011


On 02/19/2011 08:55 AM 邓卫华 wrote:
>   
> 
> Hi, 
> 
>  in our company, i want to disable imap of some users, they
> can access them mailbox by pop3 only, and another user can allow access
> them mailbox by imap or pop3. 
> 
> how can i do ? 
> 

Its really simple - since you are using a SQL backend for your passdb.
Didn't you?

Create your table* like:

       user       | password | etc ... | smtp | pop3 | imap | sieve
------------------+----------+---------+------+------+------+-------
 user at example.com | XXX      |         | t    | t    | t    | t


And a password_query like:

SELECT user, password FROM tbl WHERE user = %s and %s

* = the columns smtp, pop3, imap and sieve have the type boolean.
    Rename sieve to managesieve if you are using Dovecot < 1.2.beta2


Regards,
Pascal
-- 
The trapper recommends today: 5e1f1e55.1105009 at localdomain.org


More information about the dovecot mailing list