[Dovecot] Dovecot and "deliver" disagree on character encodings
Hi, I have a problem where Dovecot and its LDA seem to disagree on what character encoding should be used in Maildir names.
I use Dovecot and Postfix on a Debian server. Mail is delivered by Dovecot LDA (called from .forward) and sorted according to a Sieve script into a number of Maildir folders in my home directory. Dovecot serves the mail over IMAP and I read it in Kmail.
I originally created the mail folders with Kmail, and Dovecot created the directories with their names encoded in modified UTF-7, like in IMAP. The Sieve script is encoded in UTF-8, in accordance with RFC 3028. When the Sieve script specifies a mail folder with non-English letters in the name, the LDA doesn't put the messages in the corresponding modified-UTF-7-encoded directory. Instead it creates a new directory with the same name but encoded in UTF-8. That directory doesn't show up as a mail folder in Kmail, presumably because Dovecot considers the UTF-8-encoded name invalid.
The Dovecot I got with Debian isn't exactly the most recent version. I searched for "Maildir", "deliver" and "Sieve" in the changelog, and didn't find anything about this. Should I consider upgrading anyway, abandoning the Debian package?
Here are the details:
Debian Etch (4.0) Dovecot 1.0.rc15 I don't know how to find out the version number of the Sieve plugin but it's the one that came with Dovecot in the Debian package. CPU: Intel Pentium filesystem: ext3
marvin:~# dovecot -n # /etc/dovecot/dovecot.conf log_timestamp: %Y-%m-%d %H:%M:%S protocols: imap listen: [::] ssl_cert_file: /etc/ssl/certs/mail.rombobeorn.se.pem ssl_key_file: /etc/ssl/private/mail.rombobeorn.se.key ssl_cipher_list: <too long, and can't possibly be relevant> login_dir: /var/run/dovecot/login login_executable: /usr/lib/dovecot/imap-login mail_location: maildir:~/Maildir maildir_copy_with_hardlinks: yes imap_client_workarounds: auth default: mechanisms: digest-md5 user: dovecot-auth passdb: driver: passwd-file args: /etc/dovecot/passwd userdb: driver: passwd socket: type: listen client: path: /var/spool/postfix/private/auth mode: 432 user: postfix group: postfix master:
beorn@marvin:~$ cat .forward | "/usr/lib/dovecot/deliver -c /etc/dovecot/deliver.conf"
beorn@marvin:~$ cat /etc/dovecot/deliver.conf protocol lda { postmaster_address = postmaster@xn--rombobjrn-67a.se mail_plugins = cmusieve }
Apart from this problem, thanks for a very good IMAP server!
Björn Persson
On Mon, 2008-08-25 at 01:53 +0200, Björn Persson wrote:
I originally created the mail folders with Kmail, and Dovecot created the directories with their names encoded in modified UTF-7, like in IMAP. The Sieve script is encoded in UTF-8, in accordance with RFC 3028. When the Sieve script specifies a mail folder with non-English letters in the name, the LDA doesn't put the messages in the corresponding modified-UTF-7-encoded directory. Instead it creates a new directory with the same name but encoded in UTF-8. That directory doesn't show up as a mail folder in Kmail, presumably because Dovecot considers the UTF-8-encoded name invalid.
Dovecot isn't working right here, but since there's currently no UTF8->mUTF7 conversion code in Dovecot it's not too simple to fix this. I added it to my TODO.
The Dovecot I got with Debian isn't exactly the most recent version. I searched for "Maildir", "deliver" and "Sieve" in the changelog, and didn't find anything about this. Should I consider upgrading anyway, abandoning the Debian package?
Here are the details:
Debian Etch (4.0) Dovecot 1.0.rc15
You could (and probably should) get a newer version from backports.org.
participants (2)
-
Björn Persson
-
Timo Sirainen