Quoting Marcin Mirosław <marcin@mejor.pl>:
W dniu 2014-05-05 19:21, Marcin Mirosław pisze:
W dniu 2014-05-05 18:39, SIW pisze:
I use MySQL to store my virtual users passwords and I am running the latest version of Dovecot.
What I need to do is have one particular user have ONLY access to their email via Roundcube (webmail) and no IMAP/SMTP access.
Therefore, how do I disable IMAP/SMTP access for just one user?
Hi! Use variable %s in query (http://wiki2.dovecot.org/Variables ). E.g. you can use new column in table or use CASE in SELECT statement if you don't need to change schema of table.
Simpler query could look SELECT foo FROM bar WHERE ... AND (%u!='blocked@user' AND %s != 'imap')
You can also use Bit Operators directly via SQL - like in vpopmail.