Closed Bug 1490331 Opened 6 years ago Closed 5 years ago

Mime Encoding issue in message telling the user to install enigmail in French

Categories

(MailNews Core :: MIME, defect)

defect
Not set
normal

Tracking

(thunderbird_esr6065+ fixed, thunderbird66 fixed, thunderbird67 fixed)

RESOLVED FIXED
Thunderbird 67.0
Tracking Status
thunderbird_esr60 65+ fixed
thunderbird66 --- fixed
thunderbird67 --- fixed

People

(Reporter: bigon, Assigned: infofrommozilla)

Details

Attachments

(2 files)

Attached image screenshot.png
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:62.0) Gecko/20100101 Firefox/62.0
Build ID: 20180905224245

Steps to reproduce:

Hello,

On my machine here I just received an encrypted mail, but I don't have enigmail installed. I get a message telling me to install it. The problem is that the encoding of the accentuated characters is wrong


Actual results:

Wong encoding of accentuated characters


Expected results:

Characters properly displayed
How ugly. Your screenshot shows an UTF-8 encode messages displayed as Western/windows-1252/ISO-8859-1/ANSI. Can you change the text decoding on the View menu?

The equivalent English page is displayed in Unicode for me, so I wonder why that's not happening for you.
When switching to UTF-8 in the View menu, the message is displayed properly

But thunderbird always defaults back to Western
That appears to be the problem. We should ask some other French user. Landry, when you see the "This is an encrypted OpenPGP message. In order to decrypt this mail, you need to install an OpenPGP add-on." in French, does it display properly in UTF-8? I hope you have encrypted messages and can just switch off Enigmail for a moment.
Flags: needinfo?(landry)
I dont use enigmail so dont have it installed. Also can't seem to set the UI to a locale in 60.2.1, despite having /usr/local/lib/thunderbird-60.2.1/extensions/langpack-fr@thunderbird.mozilla.org.xpi installed (xpi comes from the signed linux xpis, but i dont see it in about:addons, no language tab) and general.useragent.locale set to fr.

By default on OpenBSD it seems 'Text encoding' is 'Unicode' by default but i have no idea what sets this default. I avoid encoding issues/settings like the plague, because it's always a nightmare to deal with...
Flags: needinfo?(landry)
SkyLined, can you assist?
Flags: needinfo?(abbGZcvu_bugzilla.mozilla.org)
Nope; I have an English Thunderbird installed.
Flags: needinfo?(abbGZcvu_bugzilla.mozilla.org)
(In reply to Laurent Bigonville from comment #2)
> When switching to UTF-8 in the View menu, the message is displayed properly
> 
> But thunderbird always defaults back to Western

Workaround:
Open the context menu of the folder where the mail is located.
'Properties' -> 'Fallback Text Encoding:'
select "Unicode (UTF-8)"

This message is TB generated. So TB should overwrite the encoding automatically.

So there is a bug? Or no?

The thing I don't understand is that the pseudo-message we generate if Enigmail is not installed declares that the message is UTF-8 encoded.

https://dxr.mozilla.org/comm-central/source/comm/mailnews/mime/cthandlers/pgpmime/nsPgpMimeProxy.cpp#384

(In reply to Patrick Brunschwig from comment #9)

The thing I don't understand is that the pseudo-message we generate if Enigmail is not installed declares that the message is UTF-8 encoded.

https://dxr.mozilla.org/comm-central/source/comm/mailnews/mime/cthandlers/pgpmime/nsPgpMimeProxy.cpp#384

Yes, but that must be like this:

temp.AppendLiteral("Content-Type: text/html; Charset=utf-8\r\n\r\n<html><body>");

It works in the debugger.
I can upload a patch. Who is doing the review?

Guys, thanks for looking into it. Can you please post permalinks in the future.

I'll review right now if you want.

Comment on attachment 9042763 [details] [diff] [review]
Declare the correct character set in the PGP-AddOn-is-missing message

Thanks, I can't believe how, well, how to say it nicely, unfortunate the original code was :-(
Attachment #9042763 - Flags: review?(jorgk) → review+
Attachment #9042763 - Flags: approval-comm-esr60+
Attachment #9042763 - Flags: approval-comm-beta+

Pushed by mozilla@jorgk.com:
https://hg.mozilla.org/comm-central/rev/e925b04e3bc2
Declare the character set correctly in the "PGP add-on is missing" message. r=jorgk

Status: UNCONFIRMED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → Thunderbird 67.0

(In reply to Jorg K (GMT+1) from comment #13)

Thanks, I can't believe how, well, how to say it nicely, unfortunate the
original code was :-(

"Stupid" would be a good word (being the author of that line, I'm allowed to say that) :-(

Hmm, well, I didn't spot the mistake when I looked at comment #9. Just a matter of not seeing the forest for the trees ;-)

Assignee: nobody → infofrommozilla
Component: Untriaged → MIME
Product: Thunderbird → MailNews Core
Summary: Encoding issue in message telling the user to install enigmail in French → Mime Encoding issue in message telling the user to install enigmail in French
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: