GMX (non-ASCII trash name, no UTF8=ACCEPT): trash flag lost after restart, deleted messages are expunged
Categories
(MailNews Core :: Networking: IMAP, defect)
Tracking
(thunderbird_esr153 affected)
| Tracking | Status | |
|---|---|---|
| thunderbird_esr153 | --- | affected |
People
(Reporter: ingowertenbruch, Assigned: ndo84bw)
References
(Regression)
Details
(Keywords: dataloss, regression)
Attachments
(1 external file)
Steps to reproduce
- create a new mail account in Thunderbird for any "@gmx.de" account
- select any email, for example from your inbox
- press delete
Actual results
The server setting "When I delete a message" is set to "Move it to this folder", but no folder is selected ("Choose Folder")
Result: The mail is permanently deleted and therefore lost
Expected results
If, for any reason, no valid folder is selected in the server settings "When I delete a message", then any deletion attempt should throw an error or should be moved to "local folders/Trash" instead, but must not be deleted permanently
Reproduced on 153.6.0esr with a fresh profile and a GMX account. GMX does not offer UTF8=ACCEPT and its trash folder is "Gelöscht" (\Trash special-use).
- After account setup, "Gelöscht" has the trash flag, but
trash_folder_nameis stored as MUTF-7:Gel&APY-scht. - After a restart, folder discovery compares that value with the UTF-8 name
Gelöscht, finds no match and clears the trash flag. - With no trash folder, deleting a message expunges it. A test message was gone, not in "Gelöscht".
In nsImapIncomingServer::DiscoveryDone, bug 1958781 converted the compared path to UTF-8, but both places that write the pref still store the raw server path.
On 154 and later, bug 2047462 keeps the server's special-use flags, so deleting works, but the pref is still wrong and Server Settings show "Choose Folder".
Fix proposal: convert the path to UTF-8 before writing the pref. Without that fix, uplifting bug 2047462 to ESR 153 would stop the data loss.
On servers without UTF8=ACCEPT, folder discovery stored the trash path as
MUTF-7, e.g. "Gel&APY-scht" for "Gelöscht", but compares it as UTF-8. On the
next start the trash folder lost its flag, Server Settings showed "Choose
Folder", and deleted messages were expunged instead of moved.
Discovery now stores UTF-8. Profiles that already have the MUTF-7 path get it
rewritten on the next discovery and keep their trash folder.
Updated•17 days ago
|
Pushed by jtracey@thunderbird.net:
https://hg.mozilla.org/comm-central/rev/f4dbe96efbb1
Store the IMAP trash folder path as UTF-8 so a non-ASCII trash folder survives a restart. r=mkmelin
Comment on attachment 9678546 [details]
Bug 2085365 - Store the IMAP trash folder path as UTF-8 so a non-ASCII trash folder survives a restart. r=#thunderbird-back-end-reviewers
Uplift Approval Request
- Please state case for uplift consideration and ensure bug severity is set: Dataloss regression from bug 1958781. On IMAP servers without UTF8=ACCEPT and a non-ASCII trash folder (e.g. GMX "Gelöscht"), the trash folder loses its flag after a restart and deleted messages are expunged instead of moved. On 154+ this is partly hidden by bug 2047462, but ESR 153 is fully affected.
- User impact if declined: Deleted messages are permanently lost for these users, without a warning.
- Is this code covered by automated tests?: Yes
- Has the fix been verified in Daily?: No
- Has the fix been verified in Beta?: No
- Needs manual test from QA?: No
- If yes, steps to reproduce:
- List of other uplifts needed: None
- Risk to taking this patch: Low
- Why is the change risky/not risky? (and alternatives if risky): Only the stored trash folder path changes from MUTF-7 to UTF-8, and existing MUTF-7 values are rewritten once. The central patch doesn't apply to esr153. An adapted esr153 patch with its own test is ready, try is green apart from known failures, and I tested it on 153.7 with a real GMX account. I'll attach it once this is approved.
- Does the fix cause any migrations to be skipped?: No
- String changes made/needed: None
Description
•