[Dovecot] Hierarchy separator usage -- and a bijou bug? (was: Prayer, Maildir and Folders whose names begin with ".")

Timo Sirainen tss at iki.fi
Tue Mar 13 18:51:02 EET 2007


On Tue, 2007-03-13 at 16:45 +0000, Mike Brudenell wrote:

>      File:       src/imap/commands-util.c
>      Function:   client_verify_mailbox_name()

A better place would be src/lib-storage/index/maildir/maildir-storage.c
maildir_is_valid_create_name().

> Timo:  I may have spotted another instance of a mailbox name being  
> returned using the wrong hierarchy separator character (in Dovecot  
> 1.0rc24 with separator set to "/").  Here:
> 
> a01 login pmb1 secretpassword
> a01 OK Logged in.
> a02 select a//b          <========================== Asked with //
> a02 NO Mailbox doesn't exist: a..b     <============ Reply with ..

Yes, I also noticed these a while ago but then thought that no-one
cares. :)

> I'm confused how client_verify_mailbox_name() is detecting two or  
> more of either "." or "/" as the code looks to only check one  
> separator character (obtained from mail_storage_get_hierarchy_sep 
> (storage))
> 
> Or is this returning the separator character maildir is using (".")  
> and not the hierarchy separator which we have changed in the Dovecot  
> configuration file to "/"?  If so then my code fragment isn't going  
> to work, as the Maildir filestore separator will continue to be "." :-(

That code is only verifying the separator from namespace configuration.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://dovecot.org/pipermail/dovecot/attachments/20070313/0f7b3c25/attachment.pgp 


More information about the dovecot mailing list