On Tue, 2005-04-26 at 17:50 +0200, Jakob Curdes wrote:
Is there a way to restrict access to imap on a per-user basis ? Situation is as following : internal server w/many users, some users work also from home. I would like to make their mailboxes accessible from outside via imaps, but only for selected users with strong passwords. If dovecot would run via inetd, I could use hosts.allow patterns for this. Any idea or is this just not possible ? (I know the easiest way would be to connect via VPN but thst is not possible at the moment).
It had been possible to run Dovecot via inetd at some point, but looks like it's pretty broken right now. I tried to fix it but there are just too may bugs with it :)
But if it's enough to do the check after authentication, you can use with 1.0-stable/test:
protocol imap { mail_executable = /usr/sbin/tcpd /usr/libexec/dovecot/imap }
or with 0.99.x (although I'm not sure if it actually allows parameters.. if not, replace it with a binary that execs them):
imap_executable = /usr/sbin/tcpd /usr/libexec/dovecot/imap
Another way that would already work is to creatively use %r variable and SQL passdb.