Japanese language prevents user from unsubscribing
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
GNU Mailman |
Fix Released
|
Medium
|
Mark Sapiro |
Bug Description
Hi,
When mailing list is configured with:
preferred_language = 'ja'
available_languages = ['en', 'ja']
send_goodbye_msg = 0
And mailman receives confirmation email for unsubscription with multipart message encoded in
different encoding than euc-jp, then mailmans command runner crashes with traceback:
Feb 10 18:08:00 2021 (1270) Uncaught runner exception: 'euc_jp' codec can't decode bytes in position 280-281: illegal multibyte sequence
Feb 10 18:08:00 2021 (1270) Traceback (most recent call last):
File "/usr/lib/
self.
File "/usr/lib/
keepqueued = self._dispose(
File "/usr/lib/
res.
File "/usr/lib/
results = MIMEText(
File "/usr/lib64/
self.
File "/usr/lib64/
self.
File "/usr/lib64/
self._payload = charset.
File "/usr/lib64/
s = self.convert(s)
File "/usr/lib64/
return unicode(s, self.input_
UnicodeDecodeError: 'euc_jp' codec can't decode bytes in position 280-281: illegal multibyte sequence
Here is an example of a mail which triggers this:
Date: Wed, 11 Nov 2020 14:13:16 +0900
Subject: Re: ###CONFIRM###
From: <testuser2@
To: userlist-
MIME-Version: 1.0
Content-Type: multipart/
--0000000000006
Content-Type: text/plain; charset="UTF-8"
Content-
44GT44KT44Gr44G
--0000000000006
Also its maybe worth pointing out that setting RESPONSE_
I've managed to fix this issue by decoding the message part with its original charset and then encoding it to preferred encoding of mailing list.
I'm attaching my patch. Could you please consider merging it?
Thanks for any help you can provide.
Related branches
Changed in mailman: | |
status: | Fix Committed → Fix Released |
Thank you for the patch.