[Users] encoded addresses causing problems in reply

Derek B. Noonburg derekn at foolabs.com
Wed Sep 7 19:17:37 UTC 2022


If I do a reply-all to an email with ISO-2022-JP encoded addresses, the
to/cc headers in the resulting message end up mangled.

I'm not sure exactly where this is happening -- it may or may not have
anything to do with claws -- but I'm hoping to get some advice on how
to debug the problem.

I unfortunately can't forward the email, because it's from a customer.
I understand this makes it harder to debug, but I'm hoping maybe
someone has encountered something similar, or has some other helpful
suggestions anyway.

Looking at the original email (to which I'm replying) with "view
source", the from/cc headers look like this:

From: =?iso-2022-jp?B?xxxxxxxx==?=
	<aaaa at example.com>
CC: =?iso-2022-jp?B?xxxxxxxx?=
	<bbbb at example.com>,
	=?iso-2022-jp?B?xxxxxxx==?=
	<cccc at example.com>
	=?iso-2022-jp?B?xxxxxxx==?=

When I hit reply-all, the headers in the claws compose window look
perfect.  (I don't read Japanese, but as far as I can tell, everything
looks good.)  I'm seeing:

To: JJJ / xxxx, xxxx <aaaa at example.com>
Cc: JJJ / xxxx, xxxx <bbbb at example.com>
Cc: JJJ / xxxx, xxxx <cccc at example.com>

where "J" are Japanese characters.

One suspicious thing here is that there are spaces, slashes, and
commas, and no quoting.  But I'm not sure what the rules are for
encoding email addresses (the "=?iso-222-jp...." stuff).  In the
original email headers, the spaces and punctuation are "inside" the 
encoded blobs.

If I bcc the reply to myself and view source on that, the headers are
mangled pretty badly:

To: =?iso-2022-jp?Q?=1B$B at foolabs.com>,
	#0f6Q=1B at foolabs.com (B?= / =?iso-2022-jp?Q?xxxxx?=
 =?iso-2022-jp?Q?xxxx?= <aaaa at example.com>
Cc: "=?iso-2022-jp?Q?=xxxx"@foolabs.com;, <R=1B at foolabs.com>

where "foolabs.com" is my sending domain.  The one original "to"
address (aaaa at example.com) shows up correctly amidst the gibberish, but
everything else is gone.

I can't really send a bunch of email to the customer to test this, and
I can't forward email due to confidentiality (I know this makes
debugging difficult) -- but if anyone has suggestions for how I can
debug this, I'd really appreciate it.

- Derek


More information about the Users mailing list