Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 18706 - net-mail/cyrus-imapd: 8-bit characters in e-mail headers to X
Summary: net-mail/cyrus-imapd: 8-bit characters in e-mail headers to X
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Server (show other bugs)
Hardware: All Linux
: High minor (vote)
Assignee: Net-Mail Packages
URL:
Whiteboard:
Keywords:
: 80630 (view as bug list)
Depends on:
Blocks:
 
Reported: 2003-04-03 14:46 UTC by georg.lippold
Modified: 2006-07-21 03:57 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
updated ebuild-script for cyrus-imapd (cyrus-imapd-2.1.11-r1.ebuild,6.21 KB, text/plain)
2003-04-03 14:48 UTC, georg.lippold
Details
the required diff (non-ascii-header.diff,848 bytes, patch)
2003-04-03 14:48 UTC, georg.lippold
Details | Diff
diff for manpage (imapd.conf.5.diff,958 bytes, patch)
2003-05-14 22:03 UTC, Marius Mauch (RETIRED)
Details | Diff
updated ebuild (cyrus-imapd-2.1.14.ebuild,7.17 KB, application/text)
2003-09-17 14:49 UTC, georg.lippold
Details
Updated diff (non-ascii-header.diff,853 bytes, patch)
2003-09-17 14:53 UTC, georg.lippold
Details | Diff
Patch for 2.2.12, store it under files/cyrus-imapd-2.2.12-8bitheader.patch (cyrus-imapd-2.2.12-8bitheader.patch,2.79 KB, patch)
2005-02-28 05:53 UTC, georg.lippold
Details | Diff
Updated ebuild for 2.2.12 (cyrus-imapd-2.2.12.ebuild,9.01 KB, text/plain)
2005-02-28 05:54 UTC, georg.lippold
Details

Note You need to log in before you can comment on or make changes to this bug.
Description georg.lippold 2003-04-03 14:46:03 UTC
Cyrus has a special routine that translates 8-bit (utf-8) headers in e-mails
into a big X. This seems to be a known bug, but the programmers of cyrus do not
even allow normal users to turn this feature on or off. I found an old patch under

http://asg.web.cmu.edu/archive/message.php?mailbox=archive.info-cyrus&msg=1682

that fixes that problem, but I couldn't apply it to the current cyrus-distro. So
I wrote my own patch against it and included it in the attachment. Furthermore,
I added a revised ebuild script that uses the patch. The only thing missing is a
fixed man-page for imapd.conf, but that is up to you.

Greetings,

George
Comment 1 georg.lippold 2003-04-03 14:48:04 UTC
Created attachment 10159 [details]
updated ebuild-script for cyrus-imapd

now, /etc/imapd.conf has the option

allow8bitheaders:   yes/no

(undocumented)
Comment 2 georg.lippold 2003-04-03 14:48:36 UTC
Created attachment 10160 [details, diff]
the required diff
Comment 3 georg.lippold 2003-04-03 14:49:20 UTC
Comment on attachment 10160 [details, diff]
the required diff

store it under files/non-ascii-header.diff
Comment 4 Marius Mauch (RETIRED) gentoo-dev 2003-05-14 22:03:29 UTC
Created attachment 12000 [details, diff]
diff for manpage

Added a description for the new "allow8bitheaders" setting and changed the
description of "reject8bit".
Comment 6 georg.lippold 2003-09-17 14:49:32 UTC
Created attachment 17922 [details]
updated ebuild

Do you still care about this bug? I just upgraded to 2.1.14 and the patch
almost worked... Here an updated ebuild-script... and the slightly modified
patch follows
Comment 7 georg.lippold 2003-09-17 14:53:41 UTC
Created attachment 17923 [details, diff]
Updated diff
Comment 8 Janne Pikkarainen 2003-11-03 04:43:15 UTC
I'm definitely interested about this patch and am ready to help you with
it, if there's something I could do. I'm about to deploy Cyrus to couple
of production servers but this 8-bit header thing is a show-stopper for me.
Comment 9 Heinrich Wendel (RETIRED) gentoo-dev 2004-03-09 06:49:57 UTC
what's the status of this?
Comment 10 Max Kalika (RETIRED) gentoo-dev 2004-03-09 08:58:47 UTC
Ok, first of all, this is not a bug.  As Nick's link in comment #5 states, the IMAP RFC (2060 Section 7.4.2) does not allow 8-bit characters in headers:

   8-bit textual data is permitted if a [CHARSET]
   identifier is part of the body parameter
   parenthesized list for this section.  Note that
   headers (part specifiers HEADER or MIME, or the
   header portion of a MESSAGE/RFC822 part), MUST be
   7-bit; 8-bit characters are not permitted in
   headers.  

This is because things like searching and sorting can potentially break.  Another message from the cyrus dev is here explaining this:

  http://asg.web.cmu.edu/archive/message.php?mailbox=archive.cyrus-devel&msg=146

Even though debian folks applied this patch (it seems) I'm not comfortable doing it in Gentoo, because we may potentially be getting bugs about random searches failing due to 8bit headers.  Thoughts?
Comment 11 Janne Pikkarainen 2004-03-09 09:25:00 UTC
I don't see what's the problem, if this option is not turned on by default and comes with all the necessary "Enabling this can _really_ screw up things" disclaimers.

Potentially nasty patches are unfortunately needed every now and then in more exotic countries, that's for sure. I for one (as a Finn) know that. :-(
Comment 12 Tuan Van (RETIRED) gentoo-dev 2005-02-03 13:35:19 UTC
*** Bug 80630 has been marked as a duplicate of this bug. ***
Comment 13 Tuan Van (RETIRED) gentoo-dev 2005-02-03 13:36:22 UTC
Note: the dup has a newer patch.
Comment 14 Holger Hoffstätte 2005-02-03 13:51:05 UTC
OK I'm getting old - I just provided a duplicate for this bug (including ebuild+patch) even though I'm CC'ed to this one. Anyway, it's very obvious that the CMU folks are approaching this from a very standards-compliant, yet still very academic POV, and unfortunately a very US-centric at that. Fact is that many European/Eastern folks _do_ send mail that is not RFC-whatever compliant and telling them to fix that is just totally futile (ISP's webmail etc.); you still get a 'X' in your mail, which "potentially messes up search" as well. The patch does not break anything that doesn't already break by _falsifying_ the subject; actually I'd say the 'X' is even worse because I don't have the chance of properly displaying the subject at all. But regardless of all that: like I wrote in my other bug I simply suggest an allow8bit / munge8bit USE flag and be done with it. That's what Gentoo is all about, that's why I just spent ~1h of my time on this.
Comment 15 georg.lippold 2005-02-05 15:22:54 UTC
I agree with Holger. Gentoo is about configuring things to your own needs, so just make this availiable to all non-US Citizens. You don't have to use it, but it doesn't break anything either. I wonder if the pound-sign is in the seven bit set? Any Englishmen reading this?
Comment 16 Arnaud Launay 2005-02-17 02:19:11 UTC
Especially as it is disable by default, one for sure should know what he's doing when using this patch.
Comment 17 georg.lippold 2005-02-28 05:53:43 UTC
Created attachment 52298 [details, diff]
Patch for 2.2.12, store it under files/cyrus-imapd-2.2.12-8bitheader.patch

Revised patch for 2.2.12
Comment 18 georg.lippold 2005-02-28 05:54:26 UTC
Created attachment 52299 [details]
Updated ebuild for 2.2.12
Comment 19 georg.lippold 2005-02-28 05:55:23 UTC
Comment on attachment 52298 [details, diff]
Patch for 2.2.12, store it under files/cyrus-imapd-2.2.12-8bitheader.patch

when will you integrate it?
Comment 20 Fernando J. Pereda (RETIRED) gentoo-dev 2005-03-01 12:02:28 UTC
I'll take care of this. Anyway, do *NOT* post bugs you can only reproduce using this patch as we don't support third party patches.

Cheers,
Ferdy
Comment 21 Fernando J. Pereda (RETIRED) gentoo-dev 2005-03-02 04:54:02 UTC
Commited cyrus-imapd-2.2.12-r1 with unsupported_8bit use flag to enable the patch in #80630.

Compiles for me, test it and give feedback; reopen if it fails *to compile* for you.

Cheers,
Ferdy
Comment 22 georg.lippold 2005-03-06 15:18:35 UTC
works for me on three systems (athlon, pentium-III, dual-athlon)
Comment 23 Fernando J. Pereda (RETIRED) gentoo-dev 2005-03-08 04:53:48 UTC
Reopen to fix. This is annoying :P

Cheers,
Ferdy
Comment 24 Fernando J. Pereda (RETIRED) gentoo-dev 2005-03-08 04:54:12 UTC
Fixed.

Cheers,
Ferdy
Comment 25 Janne Pikkarainen 2005-10-22 01:49:44 UTC
I wonder why this patch isn't included in any stable cyrus-imapd ebuilds, since
this patch is very, very useful and hassle-free thing for many people.
Comment 26 Arnaud Launay 2005-10-22 01:57:58 UTC
I agree with that, it's stable as hell, and should go mainstream ASAP.

BTW, I should open a new bug to propose a patch to disable sieve, too.
Comment 27 Janne Pikkarainen 2006-07-21 03:57:15 UTC
Hello? Anyone? cyrus-imapd-2.2.12-r4 really should be marked as stable already. Besides of this bug, there is at least one more reason for that:

http://forums.gentoo.org/viewtopic-t-482096.html