[Dovecot] Help needed with plugin - Read Only access to IMAP mailbox

Chris Moules chris at gms.lu
Wed Aug 25 16:51:48 EEST 2010


Timo Sirainen wrote:
> On Wed, 2010-08-25 at 11:59 +0200, Chris Moules wrote:
> 
>> Option 1: ACL
>> This can work, but not if the mailbox(s) can change without you knowing how. I.E. a online read-only archive of someone else's 
>> mailbox. There is no wild-card or recursive ACL options. Rsync style backups don't allow for easy creation of custom ACL files 
>> per mailbox.
> 
> I think you could pretty easily add support for "default ACL file" that
> is used instead of the internal ACL defaults. I've been planning on
> doing that at some point anyway. Maybe ~/Maildir/dovecot-acl-default or
> something.

So, that should be a patch to the current ACL plugin?
Any pointers on where to start with that? I only started on dovecot plugin programming yesterday. The ACL plugin seemed the most 
complex so I avoided it for 'learning'.

> 
>> The plugin forces the MAILBOX_OPEN_READONLY flag in a mailbox_open() call.
> 
> Yeah .. this flag isn't enforced much really.. I think I should just
> remove it.
> 

Well, that explains why it seemed to work, but not really.
An alternative to removing it could be to enforce it...

As a quick fix, I can combine my current plugin with my read only filesystem hack. At lease with this I only get a SERVERBUG 
message when I try to copy or move a mail.

Regards

Chris


More information about the dovecot mailing list