Special characters in folder name not handled correctly - They should be either escaped or refused with warning to end-user
Categories
(Thunderbird :: Folder and Message Lists, defect)
Tracking
(Not tracked)
People
(Reporter: richard.leger, Unassigned)
References
(Blocks 1 open bug)
Details
Special characters in Folder names are not currently handled correctly by Thunderbird causing situation where folder is created but not accessible and currently impossible to correct/revert as folder can no longer be renamed or deleted!
This is an issue that has been affecting TB for quite a long time...
What I do:
- Create a Local Folder with a forwards slash e.g My/Folder
or - Create an IMAP folder with a trailing space ("My Folder ") or with three trailing dots ("My Folder...", etc...
What happens:
Folder name mismatch between folder name displayed in TB and effective folder name created on system either Windows or IMAP server...
- Folders are created and appearing without errors in TB but:
-- folder become inaccessible - mismatch between folder name in system and TB
-- folder cannot be renamed - because of mismatch
-- in addition of above, IMAP folder cannot sync properly with the server
-- sometime when clicking on the folder an alert appears: "Unable to open the folder My/Folder because it is in use by other operations..."
What to expect:
-
Spaces shall be trimmed
-
Special characters (such as used by IMAP path separator or Windows system e.g any refused in folder names) should be either escaped before being processed by TB for creation on Windows, on IMAP server...
Or simply refused with warning alert to end-user that folder contains special characters that cannot be used in folder names, showing an exclusion list and keep the folder name open for edition till it match acceptable format for folder creation.
-- Escaped/Excluded characters shall include:
--- Any OS excluded characters for folder names
--- Any IMAP protocol characters especially the path separator character (which is often configurable on IMAP and may differ from one implementation to another.. often use slash, backslash or dot... but can be queried by client I believe...)
| Reporter | ||
Comment 1•5 years ago
|
||
I found this...
https://stackoverflow.com/questions/1976007/what-characters-are-forbidden-in-windows-and-linux-directory-names
Not an official reference but maybe a good start?
Maybe in the error alert to end-user suggest replacement authorised characters like -(dash), _(underscore) as better/safer separator for improved interoperability...
For spaces, you could trim beginning and end, as well as multiple space into one between words?
Another point of relevance is the case of the folder name indeed in Windows folder name are case insensitive... but some IMAP server may be case sensitive... meaning that TB shall carefully treat change of cases while renaming a folder... MyFolder to myfolder would be consider as the same folder on Windows but not on IMAP server with case sensitivity :-)
Outlook is very bad at that himself... would be great if TB would somehow be able to master such case issues... with grace... especially on Windows :-)
Updated•5 years ago
|
Comment 2•4 years ago
|
||
This seems to be a duplicate and fallout of https://bugzilla.mozilla.org/show_bug.cgi?id=29926 not getting properly fixed for 22 years!
| Reporter | ||
Updated•2 months ago
|
| Reporter | ||
Comment 3•2 months ago
|
||
As posted here https://thunderbird.topicbox.com/groups/android-beta/T17d8a14f58b5ddeb-M980a606af9e3d269d5905e3b also to take in consideration for escaping special characters in folder names upon new folder creation:
"...
Some IMAP servers use a dot (.) as a folder separator, while others use a slash (/). The specific separator is an implementation detail of the IMAP server.
Why Separators Differ 🤷♀️
The IMAP protocol itself doesn't mandate a specific folder separator. This leads to different server software using different conventions.
Dot-based separators are common in older systems and those using the Maildir storage format, which often represents subfolders by adding a dot to the parent folder's name (e.g., INBOX.Sent).
Slash-based separators are popular because they align with the directory hierarchy used in file systems like Unix/Linux. Servers like Dovecot and Cyrus IMAP often use a slash as their default or can be configured to do so.
How Clients and Servers Handle It 🤝
When an email client connects to an IMAP server, it can determine the correct separator by issuing a LIST command. The server's response includes the hierarchy separator it uses. The client then uses this information to correctly display and manage the folder tree.
..."
| Reporter | ||
Comment 4•1 month ago
|
||
When creating a folder with exclamation mark ! the folder creation may fail on IMAP cyrus server and Thunderbird fails to create the folder silently. No alert/error shown to end-user.
Description
•