On Oct 1, 2008, at 12:57 PM, Sascha Wilde wrote:

"Matvey Soloviev" <[EMAIL PROTECTED]> writes:

I am working on implementing support for the RFC4314 ACL management commands
and responses in the ACL plugin included with dovecot
[...]

Matvey finished a first version of the IMAP front end to the ACL plugin.

You can find the changes for dovecot 1.1.3 here:
 http://hg.intevation.org/kolab/dovecot-1.1_acl-branch/
and as we decided to move on to 1.2, here:
 http://hg.intevation.org/kolab/dovecot-1.2_acl-branch/

As of writing this the changes for 1.1.3 and 1.2 are the same (but the
1.2 version isn't really tested yet).

A did a quick look, a few comments:

if(strchr(box,' ')) str_append_c(str,'\"');
str_append(str,box);
if(strchr(box,' ')) str_append_c(str,'\"');

Use instead imap_quote_append_string(str, box, FALSE);

The IMAP commands should be in a new imap-acl plugin similar to quota/ imap-quota so that the ACL plugin is usable in deliver.

Write the ACL file by creating a temp file and renaming it over the original file. That way if the process crashes the ACLs won't ever get lost. Also you don't then need to read-lock the file and it'll work nicely with all NFS setups. Easiest way to do this is:

 - file_dotlock_open()
 - write to the file
 - fsync() the file
 - file_dotlock_replace()

Attachment: PGP.sig
Description: This is a digitally signed message part

Reply via email to