Cyrus IMAP 2.1.12 and LSUB command

Ken Murchison ken at oceana.com
Thu Apr 24 19:38:07 EDT 2003


Fixed in CVS.  Thanks.


Bernd Nies wrote:
> 
> Hi,
> 
> We're using Cyrus IMAP 2.1.12 together with SquirrelMail 1.4.0 and other
> IMAP clients (Mozilla/Netscape). It seems that there is a little bug
> with listing the subscribed folders using LSUB and various mailbox
> wildcard patterns combined with the way I configured the IMAP server
> (altnamespace and unixhierarchysep).
> 
> The "%" matches all mailboxes without hierarchy delimiter. The output
> below is correct.
> 
> . LSUB "" %
> * LSUB (\Noinferiors) "/" "INBOX"
> * LSUB () "/" "Drafts"
> * LSUB () "/" "Junk"
> * LSUB () "/" "Sent"
> * LSUB () "/" "Trash"
> * LSUB () "/" "sysadm"
> * LSUB (\Noselect \HasChildren) "/" "Other Users"
> * LSUB (\Noselect \HasChildren) "/" "Shared Folders"
> . OK Completed (0.000 secs 9 calls)
> 
> The "*" matches all mailboxes including hierarchy delimiter. The output
> below is also correct.
> 
> . LSUB "" *
> * LSUB (\Noinferiors) "/" "INBOX"
> * LSUB () "/" "Drafts"
> * LSUB () "/" "Junk"
> * LSUB () "/" "Sent"
> * LSUB () "/" "Trash"
> * LSUB () "/" "sysadm"
> * LSUB () "/" "Other Users/kauf/Trash"
> * LSUB () "/" "Shared Folders/jokes"
> * LSUB () "/" "Shared Folders/mailinglists/cert-advisory at cert.org"
> * LSUB () "/" "Shared Folders/mailinglists/ietf-mta-filters at imc.org"
> * LSUB () "/" "Shared Folders/mailinglists/info-cyrus at andrew.cmu.edu"
> * LSUB () "/" "Shared Folders/mailinglists/postfix-users at postfix.org"
> * LSUB () "/" "Shared
> Folders/mailinglists/squirrelmail-users at lists.sourceforge.net"
> * LSUB () "/" "Shared Folders/tasteless"
> . OK Completed (0.010 secs 15 calls)
> 
> But SquirrelMail 1.4.0 uses the pattern "*%" which should match both.
> But the toplevel "Shared Folders" is missing.
> 
> . LSUB "" *%
> * LSUB (\Noinferiors) "/" "INBOX"
> * LSUB () "/" "Drafts"
> * LSUB () "/" "Junk"
> * LSUB () "/" "Sent"
> * LSUB () "/" "Trash"
> * LSUB () "/" "sysadm"
> * LSUB (\Noselect \HasChildren) "/" "Other Users"
> * LSUB (\Noselect \HasChildren) "/" "Other Users/kauf"
> * LSUB () "/" "Other Users/kauf/Trash"
>  >>> * LSUB (\Noselect \HasChildren) "/" "Shared Folders" <<< Missing!
> * LSUB () "/" "Shared Folders/jokes"
> * LSUB (\NonExistent \Noselect \HasChildren) "/" "Shared
> Folders/mailinglists"
> * LSUB () "/" "Shared Folders/mailinglists/cert-advisory at cert.org"
> * LSUB () "/" "Shared Folders/mailinglists/ietf-mta-filters at imc.org"
> * LSUB () "/" "Shared Folders/mailinglists/info-cyrus at andrew.cmu.edu"
> * LSUB () "/" "Shared Folders/mailinglists/postfix-users at postfix.org"
> * LSUB () "/" "Shared
> Folders/mailinglists/squirrelmail-users at lists.sourceforge.net"
> * LSUB () "/" "Shared Folders/tasteless"
> . OK Completed (0.010 secs 22 calls)
> 
> This looks like a Cyrus IMAP bug to me because "Other Users" is listed
> separately but "Shared Folders" not. RFC 3501 says:
> 
>        The character "*" is a wildcard, and matches zero or more
>        characters at this position.  The character "%" is similar to "*",
>        but it does not match a hierarchy delimiter.  If the "%" wildcard
>        is the last character of a mailbox name argument, matching levels
>        of hierarchy are also returned.  If these levels of hierarchy are
>        not also selectable mailboxes, they are returned with the
>        \Noselect mailbox name attribute (see the description of the LIST
> 
> So this pattern should be correct.
> 
> My Cyrus imapd.conf is:
> 
>         configdirectory: /var/cyrus
>         sievedir: /opt/sieve
>         lmtpsocket: /var/cyrus/socket/lmtp
> 
>         defaultpartition: default
>         partition-default: /data/mail1
>         partition-share: /data/mail2
> 
>         servername: imap.domain.tld
>         admins: cyrus root
>         unixhierarchysep: yes
>         altnamespace: yes
>         sendmail: /opt/postfix/bin/sendmail
>         logtimestamps: yes
>         defaultacl: anyone lrsp
> 
>         allowplaintext: yes
>         sasl_pwcheck_method: saslauthd
>         sasl_mech_list: PLAIN
> 
> The other IMAP clients display the folders correctly but they use
> another method of getting the list of subscribed mailboxes.
> 
> Thanks in advance for help and fixing bugs.
> 
> Regards,
> Bernd Nies

-- 
Kenneth Murchison     Oceana Matrix Ltd.
Software Engineer     21 Princeton Place
716-662-8973 x26      Orchard Park, NY 14127
--PGP Public Key--    http://www.oceana.com/~ken/ksm.pgp




More information about the Info-cyrus mailing list