Thunderbird2 gconf gmt problem 'Bad key or directory name' because of plus symbol (+)

Bug #411358 reported by GaryW
64
This bug affects 13 people
Affects Status Importance Assigned to Milestone
Mozilla Thunderbird
Confirmed
Unknown
thunderbird (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

Here is an error message for Thunderbird 2 in Jaunty

gnubyexample@k8amd:~$ thunderbird
GConf Error: Bad key or directory name: "/desktop/gnome/url-handlers/GMT+02/command": `+' is an invalid character in key/directory names
gnubyexample@k8amd:~$ date;uname -a;cat /etc/*version*;dpkg -l | grep underbird
Sun Aug 9 14:48:37 BST 2009
Linux k8amd 2.6.28-14-generic #47-Ubuntu SMP Sat Jul 25 00:28:35 UTC 2009 i686 GNU/Linux
5.0
ii enigmail 2:0.95.7-1ubuntu2 Enigmail - GPG support for Thunderbird
ii thunderbird 2.0.0.22+build1+nobinonly-0ubuntu0.9.04.1 mail/news client with RSS and integrated spam filter support
ii thunderbird-locale-en-gb 1:2.0.0.14+1-0ubuntu2 Thunderbird English language/region package

From reading this extract ( http://osdir.com/ml/os.solaris.opensolaris.desktop/2008-03/msg00020.html ):
  Subject: Re: GConf/Thunderbird error on Solaris Nevada

  "Hi Mats,I believe you download the contribute builds of Thunderbird 2, and run
it on snv_70.

For some reason, the fix is upstreamed to Thunderbird 3 alpha, but not
community version of Thunderbird 2.
Fixed in snv_68 means the fix was integrated to Thunderbird bundled
with snv_68."

...it seems that the fix for this in thunderbird2 might require some manual intervention as although the problem is well know, the fix was only incorporated in the newer thunderbird3.

Have just checked the Karmic version at:
  http://packages.ubuntu.com/karmic/thunderbird
which currently shows that version 2 of thunderbird is planned for Karmic release.

As thunderbird3 is at Beta 3 right now I can perhaps see why debian and ubuntu are sticking with Thunderbird2 just now.
  http://www.mozillamessaging.com/en-US/about/press/archive/2009-07-21-01

However it does seem a shame to ship a new release with this known gconf issue unpatched.

Revision history for this message
In , Kiuzeppe (kiuzeppe) wrote :

User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2) Gecko/20100115 Firefox/3.6
Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.7) Gecko/20100111 Thunderbird/3.0.1

If message contains string, that has word plus plus ("+") plus word plus colon (":") plus word, example "one+two:three" error message dialog
"An error occurred while loading or saving configuration information for Gecko. Some of your configuration settings may not work properly." comes.

Details button shows more information:

"Bad key or directory name: "/desktop/gnome/url-handlers/one+two/command": `+' is an invalid character in key/directory names
Bad key or directory name: "/desktop/gnome/url-handlers/one+two/command": `+' is an invalid character in key/directory names"

(yes, twice)

Reproducible: Always

Steps to Reproduce:
1. Send or receive e-mail with text one+two:tree in message body
2. View message in Message Pane, Tab or Window

Actual Results:
Error message "An error occurred while loading or saving configuration information for Gecko. Some of your configuration settings may not work properly." shows.

Expected Results:
No error message.

This is regression from Thunderbird 2.

Revision history for this message
In , Ludovic-mozilla (ludovic-mozilla) wrote :

I'm not seeing that on Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-US; rv:1.9.3a1pre) Gecko/20100128 Shredder/3.2a1pre.

Can you start Thunderbird in -safe-mode (http://kb.mozillazine.org/Safe_mode) and let me know if the issue is still present ?

If the issue is still present would it be possible for you to look into Tools -> Error console and copy the errors at the bottom of that window ?

Revision history for this message
In , Kiuzeppe (kiuzeppe) wrote :

Yes, error is present on safe mode as well. However, there are no messages on Error console.

Maybe this is Linux specific issue? I'm running CentOS 5.

Revision history for this message
In , Ludovic-mozilla (ludovic-mozilla) wrote :

let's ask another linux user.

5 comments hidden view all 107 comments
Revision history for this message
GaryW (gnubyexample) wrote :

As mentioned in the previous comment, the suggestion was that the bug was known and fixed in Thunderbird 3 tree.

Now that Thunderbird 3 (Lucid) has replaced Thunderbird 2 (Karmic) in main Ubuntu release, there seems little point in keeping this bug active.

Suggest bug is removed from the list of active bugs by janitor or next bug clearout.

6 comments hidden view all 107 comments
Revision history for this message
In , Theo-band-9 (theo-band-9) wrote :

I can confirm. I received a message with the string "(GMT+08:00)". This results in a popup error when displaying the message. Easy to reproduce by creating a new draft message pasting only this string, saving it and then viewing it:

An error occurred while loading or saving configuration information for Gecko. Some of your configuration settings may not work properly.

Bad key or directory name: "/desktop/gnome/url-handlers/GMT+08/command": `+' is an invalid character in key/directory names

It happens in safe mode as well.

Thunderbird 3.1.3
CentOS release 5.5 (Final)

Revision history for this message
In , M-wada (m-wada) wrote :

(In reply to comment #4)
> a message with the string "(GMT+08:00)".
> Bad key or directory name: "/desktop/gnome/url-handlers/GMT+08/command":
> `+' is an invalid character in key/directory names

It sounds linkify of text mail relevant issue.
Text mail? HTML mail?
Is string around GMT+08: linkified?
Is scam/phishing detection relevant?
  Tools/Options/Security, E-mail Scam
  [ ? ] Tell me if the messag I'm reading is a suspected email scam

Revision history for this message
In , Theo-band-9 (theo-band-9) wrote :

This is a plain text message. Even the email from bugzilla (your comment) triggered this bug. And in safe mode, all plugins are disabled. I also tried to manually disable all plugins that I use.
I removed some more characters from the string and this is the shortest string that I found:

T+08:0

The source of a test message:

FCC: imap://greenpeak%<email address hidden>/INBOX
X-Identity-Key: id8
Message-ID: <email address hidden>
Date: Tue, 14 Sep 2010 09:30:03 +0200
From: Theo Band <email address hidden>
X-Mozilla-Draft-Info: internal/draft; vcard=0; receipt=0; DSN=0; uuencode=0
User-Agent: Mozilla/5.0 (X11; U; Linux i686 (x86_64); en-US; rv:1.9.2.9) Gecko/20100825 Lightning/1.0b2 Thunderbird/3.1.3
To: test
Subject: test
X-Enigmail-Version: 1.1.1
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
MIME-Version: 1.0

(GMT+08:00)

Revision history for this message
In , Ludovic-mozilla (ludovic-mozilla) wrote :

*** Bug 584822 has been marked as a duplicate of this bug. ***

Revision history for this message
In , M-wada (m-wada) wrote :

(In reply to comment #6)
> This is a plain text message.
> Even the email from bugzilla (your comment) triggered this bug.

Is the problematic string with ":" linkified by Tb?
Does your problem occur with next setting unchecked?
  Tools/Options/Security, E-mail Scam
  [ ? ] Tell me if the messag I'm reading is a suspected email scam

Revision history for this message
In , Theo-band-9 (theo-band-9) wrote :

(In reply to comment #8)
> Is the problematic string with ":" linkified by Tb?
No
> Does your problem occur with next setting unchecked?
> Tools/Options/Security, E-mail Scam
Yes option is unchecked (It's Edit->Preferences, Security, E-mail Scam)
It's not enabled. I also disabled the Junk filtering. No effect as well.
> [ ? ] Tell me if the messag I'm reading is a suspected email scam
No scam , just any ordinary/flat ASCII text (only 6 characters of text is enough as shown)

Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: 7bit
MIME-Version: 1.0

T+08:0

Revision history for this message
In , Theo-band-9 (theo-band-9) wrote :

a+b:c

Even shorter example that triggers the pop-up error message.

For the record, I use:
Mozilla/5.0 (X11; U; Linux i686 (x86_64); en-US; rv:1.9.2.9) Gecko/20100825 Lightning/1.0b2 Thunderbird/3.1.3

Revision history for this message
In , Ryan-m-nelson (ryan-m-nelson) wrote :

a+b:c and T+08:0 produced the error for me.

Tell me if messages are suspect is checked for me.

Unchecking has no effect with or with out a restart of Thunderbird.

Revision history for this message
In , Theo-band-9 (theo-band-9) wrote :

(In reply to comment #11)
> Tell me if messages are suspect is checked for me.
>
> Unchecking has no effect with or with out a restart of Thunderbird.

I Confirm that Tb has been restarted (actually the option was not enabled in the first place. Did not even knew that it existed).

Revision history for this message
In , Miles-oneal (miles-oneal) wrote :

I can consistently reproduce this by opening a message that has a uuencoded file sent as a MIME attachment, regardless of whether the mail was sent from thunderbird, mutt, pine or elm.

Sending the uuencoded file as the actual message body via the "mail" command (no MIME) works fine.

This has occurred on 3.0.x (I forget which exact version) and still manifests on 3.1.4 and 3.1.5. It happens for all our thunderbird users. We are running CentOS5.

Revision history for this message
In , Mikedoo3 (mikedoo3) wrote :

I'm seeing this in Thunderbird 3.1.10 and the latest Miramar build on CentOS 5. I can't believe this isn't fixed yet. Does anyone know a workaround?

Thunderbird 2 PRINTS the error messages to standard error, Thunderbird 3 shows an annoying dialog box instead.

This is a *major* annoyance for many many users in a corporate environment.
You can just send a plain text email with a+:a in it and get the error.

Revision history for this message
In , Joshua Cranmer (jcranmer) wrote :

*** Bug 657093 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Mikedoo3 (mikedoo3) wrote :

The error popup is coming from libgnomeui. It looks like libgnomeui overrides the default gconf error handler and the libgnomeui error handler puts up the error dialog. This isn't really a bug but the developers should probably add some basic checks for bad characters in the code before calling gconf.

I noticed the configure for thunderbird says libgnomeui is "optional at runtime",
does anyone know how? Does anyone know what gnomeui really does for Thunderbird?
If it can be turned off, that would be a work around.

Revision history for this message
In , Paul-boddie-t (paul-boddie-t) wrote :

It seems like plus characters on separate lines can also trigger this annoying behaviour. For example, from a MediaWiki update message (delimited by "----"):

----
-
Follow these steps
 +
Follow the prompts. Here is an example search:
----

This produces the following error:

----
Bad key or directory name: "/desktop/gnome/url-handlers/button-apop-upwindowwillappear.-Followthesesteps+Followtheprompts.Hereisanexamplesearch/command": `+' is an invalid character in key/directory names
Bad key or directory name: "/desktop/gnome/url-handlers/button-apop-upwindowwillappear.-Followthesesteps+Followtheprompts.Hereisanexamplesearch/command": `+' is an invalid character in key/directory names
----

So anyone using the admittedly poor confirmation message feature of MediaWiki will potentially run into this at some point.

Revision history for this message
In , Erco (erco) wrote :

I can confirm as well: running thunderbird 3.1.11 on Centos 5.5.

In my case the text was in a perl script attachment someone emailed me that apparently contained the magic string that triggers the "Gecko" popup dialog error with details. In my case the "details" say:

----
Bad key or directory name: "/desktop/gnome/url-handlers/s+Frames/command": `+' is an invalid character in key/directory names
Bad key or directory name: "/desktop/gnome/url-handlers/s+Frames/command": `+' is an invalid character in key/directory names
----

..which is due apparently to the following text in the perl script:

----
        if ( /^\s+Frames:/ ) # remove Frames
----

Revision history for this message
In , Ludovic-mozilla (ludovic-mozilla) wrote :

from https://bugzilla.mozilla.org/show_bug.cgi?id=673471#c3

Ok, I was just talking to a Gnome developer about that:
Apparently while a scheme is perfectly allowed to contain a plus sign GConf never had a concept of handling those. + is explicitely marked as invalid character and there is no special handling for such a scheme.

So I see the following to resolve that issue:

1. filter those URIs in the GConf interface code
2. ignore the errors (and switch newer TB versions to GIO (see below))

About 2.: Since Gnome3 GConf usage for scheme handlers is obsolete and is handled using GIO interfaces. Firefox and Thunderbird _should_ work fine if GIO support is enabled in the builds (openSUSE is shipping its Firefox >=4 and Thunderbird >=5 builds with GIO enabled for example)
I _think_ that GIO is able to handle that but haven't checked it myself

Revision history for this message
In , Ludovic-mozilla (ludovic-mozilla) wrote :

*** Bug 673471 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Tcflorea (tcflorea) wrote :

*** Bug 702218 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Tcflorea (tcflorea) wrote :

Reproducible using Gnome 2.16.0. Not reproducible using Gnome 2.22.3

Revision history for this message
In , Mkmelin+mozilla (mkmelin+mozilla) wrote :

Confirming based on dupes.

Revision history for this message
In , Mkmelin+mozilla (mkmelin+mozilla) wrote :

*** Bug 720378 has been marked as a duplicate of this bug. ***

Revision history for this message
In , B5gpilla (b5gpilla) wrote :

To reproduce this bug, simply add a line in the mail body like "*Datum:* 13 juni 2012 10:50:55 GMT+02:00". The part "GMT+02:00" triggers the error.
The error often occurs when someone forwards a message from an iPad or Apple mail.
When adding a space between "GMT" and "+02:00" the error does not occur.

Revision history for this message
In , Erco (erco) wrote :

I'm on the email list for this bug, and Wilco's last bug report actually triggered this bug, due to its content.

Revision history for this message
In , AraKs (aracnew) wrote :

Also affects (on Ubuntu 10.04.1):
    thunderbird 13.0+build1-0ubuntu0.10.04.1
    gnome-panel 1:2.30.2-0ubuntu0.2

When a sent email contains "GMT+02:00"

Revision history for this message
In , David Martín Clavo (david-martin-clavo) wrote :

Same as Mattia, this happens when I get a mail including a date with timezone in its body text, such as an event invitation from an Outlook users.

Revision history for this message
In , Berni421 (berni421) wrote :

A reboot message from logcheck shows error Debian Squeeze with their icedove esr 10.0.3

Revision history for this message
In , Jameskuyper (jameskuyper) wrote :

(In reply to mikedoo3 from comment #16)
> .... This isn't really a bug ...

I assume that you're talking about something other than the main problem this bug report is about? Arbitrary text from messages I receive is being validated for conformance to some rules for "key/directory" names, and is triggering a warning message if it doesn't match those rules, even though there's no particular reason why the text should match those rules. That's pretty definitely a bug.

I assume, therefore, that what you're saying is that this bug is not in some particular component of the system, but in the misuse of that component. Could you explain that in a little more detail? Why is this text being passed to something which expects to receive a "key/directory" name? If there's a good reason for checking whether or not it's a key/directory name, is there some way to do so without generating an error message in contexts where it's not an error for it to fail to meet the requirements for a key/directory name?

Revision history for this message
In , Jon-mozillabugzilla (jon-mozillabugzilla) wrote :

This looks like this may be a regression now as it was first reported over two years ago and I've never hit the problem until a recent update to Thunderbird 13.0.1 which has broken both of my laptops in the same way (both running 64-bit Ubuntu 10.04 LTS)
The actual ubuntu package is 13.0.1+build1-0ubuntu0.10.04.1 from the 'lucid-updates' repository.

The format of the emails I receive has not changed in a very long time and they used to open fine. I receive frequent internal bug updates by email which contain lots of timestamps in the text like:
"*** (#1 of 1): 2012-05-24 15:37:20 GMT+00:00 <email address hidden>"

As soon as I open any of those emails I get an unlabelled popup dialog which states:
"An error occurred while loading or saving configuration information for thunderbird-bin. Some of your configuration settings may not work properly."
Clicking on [Details] gives multiple instances of the following error:
"Bad key or directory name: "/desktop/gnome/url-handlers/GMT+00/command": `+' is an invalid character in key/directory names"

Revision history for this message
In , Mark S. (sienkiew) wrote :

I tried it in some recent thunderbirds that I have sitting around. Using "foo+bar:/baz" as the string in the message body:

It is in thunderbird 9. (linux, downloaded)

It is not in thunderbird 10. (linux, Red Hat Enterprise 6)

It is in thunderbird 11. (linux, downloaded)

(In reply to Jonathan from comment #31)
>

Revision history for this message
In , Paul-boddie-t (paul-boddie-t) wrote :

It is definitely in Thunderbird ESR 10.0.4, albeit on RHEL 5.8. This discussion causes the annoying pop-up dialogue when I read it in Thunderbird.

The GNOME packages on the system appear to belong to 2.16.0 for the most part.

Revision history for this message
In , Skwebdev (skwebdev) wrote :

Can confirm the same problem:

Thunderbird 13.0.1 installed from Ubuntu Lucid 10.04 LTS Repos.

Error:
An error occurred while loading or saving configuration information for thunderbird-bin. Some of your configuration settings may not work properly.

Details:
Bad key or directory name: "/desktop/gnome/url-handlers/GMT+02/command": `+' is an invalid character in key/directory names
Bad key or directory name: "/desktop/gnome/url-handlers/GMT+02/command": `+' is an invalid character in key/directory names
Bad key or directory name: "/desktop/gnome/url-handlers/GMT+02/command": `+' is an invalid character in key/directory names
Bad key or directory name: "/desktop/gnome/url-handlers/GMT+02/command": `+' is an invalid character in key/directory names

It would be useful to know if this bug will have any real effect on how Thunderbird actually works, especially if there's any chance of corrupting my profile. If it's just an annoying error message that I can safely ignore that would be good to know.

35 comments hidden view all 107 comments
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in thunderbird (Ubuntu):
status: New → Confirmed
Revision history for this message
KennoVO (kenno-xs4all) wrote :

There seems to be a regression; the bug came back in Thunderbird 13.0.1 and 14.0 (what I have here) on Lucid. Here's the upstream bug report: https://bugzilla.mozilla.org/show_bug.cgi?id=541130

Changed in thunderbird:
importance: Unknown → High
status: Unknown → Confirmed
36 comments hidden view all 107 comments
Revision history for this message
In , Jon-mozillabugzilla (jon-mozillabugzilla) wrote :
Download full text (3.3 KiB)

I've been doing a load of additional research on this bug because it's causing me daily annoyance...

In response to Sandy Knight: This issue will not corrupt your profile.

I've hooked up gdb to thunderbird and in combination with the source code and a bit of a crash course in reading c++ I feel I know much more about the problem...

1) If my interpretation of RFC2396 is correct, then although a string like "GMT+00:00" looks obviously like a Time Zone and not a URI, it does actually match the regex for a URI schema, which is why a call is made to gconf to look for a handler.

2) GConf does not accept '+' in the names of keys or directories. This means that gconf is technically unsuitable for mapping URI handlers, except that I can find no examples of a real-world URI

3) Since at least Thunderbird 10.0.1 (and I believe much older), "GMT+00:00" would be parsed as a URI and checked with gconf. The error message "Bad key or directory name: "/desktop/gnome/url-handlers/GMT+02/command": `+' is an invalid character in key/directory names" has been around/happening for a very long time.

4) Important difference:
- The x86_x64 binary release of Thunderbird 14.0 ( ftp://ftp.mozilla.org/pub/mozilla.org/thunderbird/releases/14.0/linux-x86_64/ ) does not show popup a dialog when the error occurs
- The Ubuntu 'thunderbird_14.0+build1-0ubuntu0.10.04.1' package *does* show a popup when the error occurrs.

5) I tried diff'ing the source trees of the Ubuntu TB 14.0 source and the Mozilla TB 14.0 source and I can find no significant differences. So I think the problem is introduced dependant on how the package gets built.

6) The error message "An error occurred while loading or saving configuration information for %s. Some of your configuration settings may not work properly." is generated by the gconf global default error handler defined in libgnomeui/gnome-gconf-ui.c

**AFTER** Typing all the stuff above I decided to try diffing an 'lsof' of good and bad examples of thunderbird running. One significant difference I noticed is that the Ubuntu package is using GIO libraries whereas the Mozilla package is not.
In the config help the default is GIO-disabled:
 "--enable-gio Enable GIO support (default: disabled)"

I can now see that in fact when thunderbird triggers a pop up it is when it is using GIO and not GConf. I got confused for quite a while until I looked at the implementation of g_app_info_get_default_for_uri_scheme which ultimately uses GConf to obtain the information.

Right now I'm taking a guess that the reason this error appears as a popup in the GIO implementation is because it does not catch and return the error unlike the gconf implementation in Thunderbird. The default error_mode is GCONF_CLIENT_HANDLE_UNRETURNED, which I'm now taking to mean "Only use the default handler for errors which haven't been returned" (thus a pop-up as defined in libgnomeui).

I'll keep looking at this when I have time...

Possible Workarounds:
-----------------------
To avoid the problem (at least on a Ubuntu host,) you can use the Thunderbird binaries supplied by Mozilla
Or
You could rename/move the /usr/lib/gio/modules/libgiogconf.so file so that ...

Read more...

Revision history for this message
Jonathan Heard (jon-launchpad-jeh) wrote :

I'm yet to do a bit more research into this but I believe that Thunderbird is basically correct in what it is doing (even though it seems daft at face value)... I can also confirm that Thunderbird has been doing this for a long time and what has changed is the presentation of the gconf errors.

This issue is attributed to the Ubuntu Thunderbird package being compiled with support for GIO. If you use the binary package from mozilla then it does not should a pop up dialog.

Thunderbird chooses GIO in preference to GConf if it's available but then GIO actually uses GConf itself to do the lookup. The error handling is configured slightly differently and this results in the pop-ups.

I need to do some more tests when I have time and then I'll try to propose a fix.

28 comments hidden view all 107 comments
Revision history for this message
In , Jameskuyper (jameskuyper) wrote :

For me, the single most common circumstance which triggers this message is automated e-mails generated in connection with SubVersion activities which therefore contain the text svn+ssh://. I wouldn't mind if that text were automatically converted into an appropriate link, though I doubt that I'll ever have reason to click on such a link. However,I'd greatly prefer it to not generate a pop-up window complaining about it being an invalid key/directory name.

Revision history for this message
In , Jhorak (jhorak) wrote :

Created attachment 681454
workaround for old gconf

(In reply to <email address hidden> from comment #56)
> Comment on attachment 680081
> fix for gconf v1
>
> Sorry, we can't accept a diff against the mozilla-beta part of a comm-beta
> checkout. If you think the issue affects Thunderbird 17 then you will need
> to submit a patch against mozilla-central and get it uplifted to
> mozilla-beta.
>
> Also I'm not a reviewer for toolkit/system/gnome, please try karlt instead.

Thanks for letting me know. Lets ask Karl what he thinks of it.

Revision history for this message
In , Jhorak (jhorak) wrote :

Jonathan, could you please try to disable gio for your build and test if this workaround works? Thanks.

Revision history for this message
In , Jon-mozillabugzilla (jon-mozillabugzilla) wrote :

I've just recompiled using the unpatched TB 16.0b4 with --disable-gio and I get no errors at all (not via stdout nor popup).. Therefore I'm recompiling now with --enable-gvfs set explicitly to see if that makes a difference.
My expectation is that the unpatched source will produce the GConf errors on stdout and not give me a popup but I'm open-minded. If I get a popup I'll then apply your patch and confirm that I then don't get a popup.

TB takes forever to compile so I probably won't have an answer until tomorrow.

Thanks
Jonathan

(In reply to jhorak from comment #63)
> Jonathan, could you please try to disable gio for your build and test if
> this workaround works? Thanks.

Revision history for this message
In , Jon-mozillabugzilla (jon-mozillabugzilla) wrote :

(In reply to era eriksson from comment #59)
> So how about limiting the scope of the fix even further? It seems that the
> majority of the complaints are about patterns where the plus sign follows
> straight after the colon. While there are no registered URL protocols which
> start with a plus sign, it strikes me as awfully ad-hoc; but it should
> certainly limit the scope of this bug significantly. On the other hand,
> you'd still be affected if you receive emails with svn+ssh:// links in them.
My trigger pattern is part of a timestamp which contains "GMT+00:00" as a time offfset. Thunderbird is looking for a URI handler for "GMT+00" in my case.

> On the other hand, if Ubuntu is the problem, how about submitting the patch
> to https://bugs.launchpad.net/ubuntu/+source/thunderbird/+bug/411358
> instead? (They are awful at accepting patches for Firefox at least, but if
> the problem is squarely with their packaging, I hope it could be accepted.)
This affects too many distros to go after each and every one. The root problem is in GNOME2, the fact that GConf doesn't allow the plus sign in key names. I really doubt that the GNOME project will be willing to make a fundamental change to GConf to either allow pluses or to fail more gracefully but it would be fantastic if they would fix it (and that all major distros would push the update).

Revision history for this message
In , Karlt (karlt) wrote :

Comment on attachment 681454
workaround for old gconf

>+ /* This check is to avoid bug #541130 when old version of gnomevfs (2.16 tested)
>+ is installed then error window pops up if scheme is containing '+' character.
>+ Let's pretend these kind of schemes are not supported by gnomevfs. */

Are you sure gnomevfs is involved in gconf_client_get_* calls?
Can you point me at the GConf code that uses GnomeVFS, please?

> GError *err = nullptr;
> gchar *command = gconf_client_get_string(mClient, key.get(), &err);
> if (!err && command) {
> key.Replace(key.Length() - 7, 7, NS_LITERAL_CSTRING("enabled"));

Can you explain, please, why a dialog would be shown when there is a GError parameter passed to the gconf_client_get_* functions?

(Removing review request for now until we understand what is happening.)

Revision history for this message
In , Jhorak (jhorak) wrote :

(In reply to Karl Tomlinson (:karlt) from comment #66)
> Comment on attachment 681454
> fix for gconf v2
>
> >+ /* This check is to avoid bug #541130 when old version of gnomevfs (2.16 tested)
> >+ is installed then error window pops up if scheme is containing '+' character.
> >+ Let's pretend these kind of schemes are not supported by gnomevfs. */
>
> Are you sure gnomevfs is involved in gconf_client_get_* calls?
> Can you point me at the GConf code that uses GnomeVFS, please?
Sorry, I've got confused with gnomevfs (for some reason I thought gconf was part of it). The comment is invalid. This is issue with gconf of course.
>
> > GError *err = nullptr;
> > gchar *command = gconf_client_get_string(mClient, key.get(), &err);
> > if (!err && command) {
> > key.Replace(key.Length() - 7, 7, NS_LITERAL_CSTRING("enabled"));
>
> Can you explain, please, why a dialog would be shown when there is a GError
> parameter passed to the gconf_client_get_* functions?
>
> (Removing review request for now until we understand what is happening.)

I've looked into it deeper into gconf code and it seems there's a bug with forwarding GError value:
gconf_client_get_string(GConfClient* client, const gchar* key,
                        GError** err)
{
  GError* error = NULL;
  GConfValue* val;

  g_return_val_if_fail (err == NULL || *err == NULL, NULL);

  val = gconf_client_get (client, key, error);

gconf_client_get (GConfClient* client,
                              const gchar* key,
                              GError** err)
{
  g_return_val_if_fail (GCONF_IS_CLIENT (client), NULL);
  g_return_val_if_fail (key != NULL, NULL);
  return gconf_client_get_full (client, key, NULL, TRUE, err);
}

See passing of error variable, it should most likely be:
  val = gconf_client_get (client, key, &error);

When the error is NULL the handle_error use gconf_client_unreturned_error to emit unreturned error signal which subsequently leads into showing the error message.

This is valid for older gconf2 library (in my case GConf2-2.14.0). So the patch is actually workaround for systems where these old libraries are. We should probably push on gconf2 package maintainers to fix this issue in gconf2.

Revision history for this message
In , Karlt (karlt) wrote :
Revision history for this message
In , Jhorak (jhorak) wrote :

Comment on attachment 681454
workaround for old gconf

Thanks for digging these bug numbers.

Revision history for this message
In , Jon-mozillabugzilla (jon-mozillabugzilla) wrote :

(In reply to Karl Tomlinson (:karlt) from comment #68)
> Ah, yes. That explains a lot.
> http://git.gnome.org/browse/gconf/log/gconf/gconf-client.c?h=gnome-2-20
>
> I also wonder whether gconf_escape_key() should be used here.
> http://developer.gnome.org/gconf/stable/gconf-gconf.html#gconf-escape-key

Thanks for looking into this further guys - I was about to try in and either install RHEL5 or compile GConf 2.16 to try and recreate this other problem..

So we now have at least two distinct GNOME bugs which can trigger this behaviour.
1) For older versions of GVFS, the error handling is broken so it always uses the unreturned error handler (thus a popup)
2) When GIO is enabled, old versions of GIO still rely on GConf to get the URI Handlers and they pass NULL instead of a GError* so any errors will always cause a popup.

It's pretty shameful really that RHEL5 is still delivering GConf 2.16 as the error handling was actually fixed way back in 2007!

On the Ubuntu side of things - version 10.04LTS (Lucid Lynx) is about to reach the end of its support life (March 2013 I think), so I don't know whether we'd persuade them to change their Thunderbird build at this late stage. For this version of Ubuntu (which is based on Debian Squeeze), the popup issue will go away if Thunderbird is built with '--disable-gio'
This problem does not exist in Ubuntu 12.04LTS (precise pangolin) and hopefully the majority of users (including myself) will upgrade soon.

I suspect any other Debian-squeeze based distros which are hitting this issue will probably have the same root cause as Ubuntu.

I suppose Thunderbird could detect gio and gconf versions in the configure script and refuse to enable gio if it's older than a certain version (perhaps just emit a warning and then continue with gio disabled), and perhaps enable something similar to jhorak's patch if gconf < 2.20 is detected??

Revision history for this message
In , Mkmelin+mozilla (mkmelin+mozilla) wrote :

*** Bug 765029 has been marked as a duplicate of this bug. ***

Revision history for this message
In , TylerStyle (tyler-style-signup) wrote :

Confirming this bug on Ubuntu 10.04 with TB 17.0 repo package.

Revision history for this message
In , TylerStyle (tyler-style-signup) wrote :

(In reply to Tyler Style from comment #72)
> Confirming this bug on Ubuntu 10.04 with TB 17.0 repo package.

Should mention that it was triggered for me by emails with "svn+ssh://" links, which are not rendered clickable (unlike http/https)

Revision history for this message
In , Fabrice-neyret-6 (fabrice-neyret-6) wrote :

Hi guys. I came here BTWof the author of a linkifyer extension for thunderbird.
I must say I'm a bit afraid by what I read in this discussions.
- '+' IS a legal character for files in unix.
- svn+ssh: IS an extremely important url for developpers (+ forges often go with mailing-lists).
- I might be naive, but this bug sounds to me as the classical forgetting to protect a string by "" despites it might possibly contains spaces or special characters (important for FS pathes as well as plenty other kinds of strings).
- It seems unreasonable to me to decide that the problem will end with the new UbuntuLTS:
  - gnome3 has plainty of problems and bugs, and it is likely that "real computer" (ie, not tablets) user will replace it by anything else, eg, gnome2.
  - existing code might still be used under 12.04LTS (some people in CS, research and engineering do have to ensure backward compatibility, sometimes even for binaries).
  - I guess many people will stuck with 10.04LTS even after march.

As I understand it from this discussion, there are 2 identified bugs: one in gnome2 (the probably forgoten "") which must be fixed by this community, and one in thunderbird (about the popup - or before thunderbird, about the error status) for which the thunderbird community just have to release a built using --disable-gio .
Any of the 2 solutions is sufficient to fix the problem, even if it would be better to fix both.

-> could you please do this thunderbird release, and forward the gnome bug to the gnome community ? thanks.

FabriceN (Unix user since 1986).

Revision history for this message
In , Jhorak (jhorak) wrote :

(In reply to fabrice.neyret from comment #74)
> Hi guys. I came here BTWof the author of a linkifyer extension for
> thunderbird.
> I must say I'm a bit afraid by what I read in this discussions.
> - '+' IS a legal character for files in unix.
> - svn+ssh: IS an extremely important url for developpers (+ forges often go
> with mailing-lists).
> - I might be naive, but this bug sounds to me as the classical forgetting to
> protect a string by "" despites it might possibly contains spaces or special
> characters (important for FS pathes as well as plenty other kinds of
> strings).
> - It seems unreasonable to me to decide that the problem will end with the
> new UbuntuLTS:
> - gnome3 has plainty of problems and bugs, and it is likely that "real
> computer" (ie, not tablets) user will replace it by anything else, eg,
> gnome2.
> - existing code might still be used under 12.04LTS (some people in CS,
> research and engineering do have to ensure backward compatibility, sometimes
> even for binaries).
> - I guess many people will stuck with 10.04LTS even after march.
>
> As I understand it from this discussion, there are 2 identified bugs: one in
> gnome2 (the probably forgoten "") which must be fixed by this community, and
> one in thunderbird (about the popup - or before thunderbird, about the error
> status) for which the thunderbird community just have to release a built
> using --disable-gio .
> Any of the 2 solutions is sufficient to fix the problem, even if it would be
> better to fix both.
>
> -> could you please do this thunderbird release, and forward the gnome bug
> to the gnome community ? thanks.

In comment 67, 68 and 70 we've come into conclusion this bug is in old gconf. The patch I've made is only a workaround, not actual fix. You should probably push on gconf package maintainers and let them fix this problem. It's already fixed in upstream.

Revision history for this message
In , hawran (hawran.diskuse) wrote :

Hi,
I'm trying to write my answer to an email and I'm getting this annoying message boxes repeatedly:

Bad key or directory name: "/desktop/gnome/url-handlers/GMT+03/command": `+' is an invalid character in key/directory names
Bad key or directory name: "/desktop/gnome/url-handlers/GMT+03/command": `+' is an invalid character in key/directory names

-----

Name: Thunderbird
Version: 17.0.5
User Agent: Mozilla/5.0 (X11; Linux i686; rv:17.0) Gecko/20130330 Thunderbird/17.0.5

10.04 LTS - the Lucid Lynx
GNOME gnome-about 2.30.2
Linux cz994691-L 2.6.32-48-generic-pae #110-Ubuntu SMP Fri May 31 19:21:42 UTC 2013 i686 GNU/Linux

Revision history for this message
In , Jean Christophe André (progfou) wrote :

Hi,

Thanks mainly to Jonathan and jhorak work, I've come to find an easy solution to manage this problem without patching/recompiling anything.

We just need to intercept the gconf_client_get_string call using LD_PRELOAD to make it answer nicely on a search containing a '+' symbol.

You will find an example how to do it at http://git.auf.org/?p=auf-poste-client.git;a=tree;f=lucid/auf-thunderbird-hack

This example is very specific to Ubuntu “Lucid Lynx” 10.04 LTS, because it is our current concern for now. But it's only about 20 lines of code so it should be easy to adapt to any other context.

Thanks to everyone for their comments here, which allowed me to manage this problem quite fast, in about half a day!

Greetings, J.C.

Revision history for this message
In , Lester-y (lester-y) wrote :

Thunderbird has just updated to the latest version, and I'm having the same problem with emails containing the timezone in the text (+02:00 GMT).
I'm using Fedora and Thunderbird 24.1.0

How do I go about fixing this

Revision history for this message
In , André Pirard (a.pirard) wrote :

(In reply to Lester Canninga from comment #78)
> How do I go about fixing this

A user-oriented bug system normally contains, beside "Bug report", a "How to fix or workaround" box explaining that in everyone's terms. Sometimes, WONTFIX or WILLSLEEP of "annoying features" stain the wonderful picture of a program and some users like this one compensate:
Permanent List-all-tabs Button 1.0 No Restart by Siddhartha Dugar
Bring back the List-all-tabs button (Removed from Firefox 12 in Bug 714281)

In this case, just change the annoying string if you edit or use Paolo's HTML edit if that's e-mail you archive.

Revision history for this message
In , Vseerror (vseerror) wrote :

*** Bug 770147 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Yuan Chao (yuanchao) wrote :

Same problem appear to be in 24.1.0. (didn't see this before) This is upgraded from the official tarball package under my home directory. OS is ubuntu.

Bad key or directory name: "/desktop/gnome/url-handlers/GMT+01/command": `+' is an invalid character in key/directory names
Bad key or directory name: "/desktop/gnome/url-handlers/GMT+01/command": `+' is an invalid character in key/directory names

Name Thunderbird
Version 24.1.0
User Agent Mozilla/5.0 (X11; Linux i686; rv:24.0) Gecko/20100101 Thunderbird/24.1.0

Application Build ID 20131023145339

Lightning 2.6.1

Revision history for this message
In , Karlt (karlt) wrote :

This Gecko code should use gconf_escape_key() on aScheme:
http://hg.mozilla.org/mozilla-central/annotate/545887140a1b/toolkit/system/gnome/nsGConfService.cpp#l239

If the error message is happening with GIO and the libgsettingsgconfbackend then something there must not be escaping the '+' correctly.

Revision history for this message
In , Mcarey-3 (mcarey-3) wrote :

This appears to be a regression. I get no error popup in Thunderbird 17.0.8 but I do get a popup when viewing the same message in Thunderbird 24.0.1, 24.1.0, and 24.1.1. Furthermore, my version of gconf already includes the fix mentioned in comment 67.

Name: Thunderbird
Version: 24.0.1
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.0.1

Scientific Linux 6.4
GNOME 2.28.2

Revision history for this message
In , Karlt (karlt) wrote :

Thunderbird 24 would use GIO, while 17 used only GConf, so I suspect the latest reports would be something in GIO or the libgsettingsgconfbackend not escaping the '+' correctly.

Revision history for this message
In , Bernd-nies (bernd-nies) wrote :

We have some hundreds RHEL 6.5 workstations for developers and Red Hat recently updated to Thunderbird 24.2.0. All developers are using subversion and this issue is pretty annoying. Is there any way for a workaround except than downgrade to an older Thunderbird version?

The Thunderbird 17 ESR lasted only one year. The ESR time frame should be larger (3 years). Users want a stable product that works and is secure and not always new features with new bugs.

Revision history for this message
In , Mozilla-6 (mozilla-6) wrote :

This is issue is especially annoying since some other mail programs (such as com.android.email) are routinely generating mails with attribution lines that trigger this bug:

<div>-------- Ursprüngliche Nachricht --------</div><div>Von: Alain Knaff <email address hidden> </div><div>Datum:16.01.2014 10:35 (GMT+01:00) </div><div>An: Xxx Xxx <email address hidden> </div><div>Betreff: Re: Tva rechner </div><div>
</div>On 16/01/14 10:34, Alain Knaff wrote:

(Bug triggered by the GMT+01:00)

Granted, that attribution line itself looks kind'a iffy, but it's hard to argue to people using com.android.email when it's in reality Thunderbird's fault to misbehave on _contents_ of a message, even if that contents is dodgy.

Revision history for this message
In , Jon-mozillabugzilla (jon-mozillabugzilla) wrote :

It's been quite a while since I've looked at this bug as I no longer hit it myself due to using a new linux distro with a full GIO implementation, plus I no longer regularly receive the kind of emails which trigger this...

Please read back to comments 67 through to 70 ( https://bugzilla.mozilla.org/show_bug.cgi?id=541130#c70 ) where we established that there are significantly different ways to hit the same problem.

For anyone running RHEL or CentOS I'm going to hazard a guess that you're not hitting the cause I encountered under Ubuntu, but instead the cause that jhorak discovered, whereby the very old version of GVFS in Red Hat has a bug whereby these messages will always be shown in a pop-up console window.

I think the only way forward to cleanly fix this issue if for Thunderbird to contain an exception that if it thinks it's found a possible URL and wants to seek a handler - if that string contains a '+' sign and either GVFS or GIO are in use, then do not look for a handler.

hope this helps.
Jonathan

Revision history for this message
In , Mozilla-6 (mozilla-6) wrote :

(In reply to Jonathan from comment #87)
[...]
> For anyone running RHEL or CentOS I'm going to hazard a guess that you're
> not hitting the cause I encountered under Ubuntu, but instead the cause that
> jhorak discovered, whereby the very old version of GVFS in Red Hat has a bug
> whereby these messages will always be shown in a pop-up console window.

Indeed, I just checked here at home (where I have Ubuntu 12.04), and I do not hit the problem.

The problem only seems to occur at work (CentOS 6.x)

Thanks for the info

Revision history for this message
In , Michaey (michaey) wrote :

This bug still exists in the latest nightly build (31 Jan 2014) of Thunderbird 24.3.0 on Debian 6. The gvfs version is 1.6.4.

A plain text message containing nothing but foo+bar:baz will trigger the bug every time the message is displayed. Surely it must be possible to validate possible URLs before handing them to gvfs?

Revision history for this message
In , Stephan-wehr (stephan-wehr) wrote :

Environment: CentOS release 6.5 x86_64 (KDE 4.11.2)
Thunderbird: 24.3.0 (safe mode)
Other: gnome-desktop 2.28.2, gtk2 2.20.1, xulrunner 17.0.10

Mail contains:
 PATH : /usr/local/bin:/usr/bin:/system/Windows/system32:<-snip->:/tools/windows/portable/Notepad++:<-snip->

Error message:
An error occurred while loading or saving configuration information for thunderbird. Some of your configuration settings may not work properly.
Details:
Bad key or directory name: "/desktop/gnome/url-handlers/Notepad++/command": `+' is an invalid character in key/directory names
Bad key or directory name: "/desktop/gnome/url-handlers/Notepad++/command": `+' is an invalid character in key/directory names

Revision history for this message
Superkuh (superkuh) wrote :

I can confirm this as well.

Environment: Ubuntu 10.04.4 x86_64 (gnome 2.30.2)
Thunderbird: 17.0.5

"Bad key or directory name: "/desktop/gnome/url-handlers/GMT+01/command": `+' is an invalid character in key/directory names"

Revision history for this message
In , Bernd-nies (bernd-nies) wrote :

Any news on this issue? Or is it being postponed until all Linux distributions use the latest GNOME release?

Revision history for this message
In , Fabrice-neyret-6 (fabrice-neyret-6) wrote :

Are you sure this condition is meaningful ?
- gnome is not the only WM. Is the problem related to gnome only ?
- people are free to install the tools they want. E.g. most people I know desinstalled Unity to get a more standard interface. -> we have to be sure that a bug is obsolette even for installs differing to "Ubuntu fresh out of the box".

Moreover, I understand that the bug was due to both an abnormal "emission" by the lib and a lack of proper testing by thunderbird. Why not treating first the side that is most reachable ?

thanks,

Revision history for this message
In , Bernd-nies (bernd-nies) wrote :

Received a gvfs-1.4.3-16 patch from Red Hat that fixes it from the GIO side.

Revision history for this message
Cima (andrea-cimatoribus) wrote :

Same issue on Thunderbird 24.3.0 and Scientific Linux 6.5

Revision history for this message
In , Eliezer Croitoru (eliezer) wrote :

(In reply to Bernd Nies from comment #93)
> Received a gvfs-1.4.3-16 patch from Red Hat that fixes it from the GIO side.

Can you share this patch?

Thanks,

Revision history for this message
In , Paul Szabo (psz-maths) wrote :

Created attachment 8523379
Workaround

While we await a patch for this issue... there is a workaround described in
http://git.auf.org/?p=auf-poste-client.git;a=tree;f=lucid/auf-thunderbird-hack
that works without needing to re-build Thunderbird (but using just LD_PRELOAD
in a wrapper script); tested and "works for me" ever since TB24.

My version of the workaround, with comments on how to use, added for reference
(stressing that this is not my invention).

Cheers, Paul

Revision history for this message
In , Mozilla-6 (mozilla-6) wrote :

(In reply to Paul Szabo from comment #95)
> Created attachment 8523379
> Workaround
>
> While we await a patch for this issue... there is a workaround described in
> http://git.auf.org/?p=auf-poste-client.git;a=tree;f=lucid/auf-thunderbird-
> hack
> that works without needing to re-build Thunderbird (but using just LD_PRELOAD
> in a wrapper script); tested and "works for me" ever since TB24.

This works great. Thank you so much :-) Finally mails sent from phones no longer throw up my thunderbird.

Cheers,

Alain

Revision history for this message
In , Vseerror (vseerror) wrote :

*** Bug 849761 has been marked as a duplicate of this bug. ***

Revision history for this message
In , Vseerror (vseerror) wrote :

Sheldon, what do you make of this?

Changed in thunderbird:
importance: High → Medium
Changed in thunderbird:
importance: Medium → Unknown
Displaying first 40 and last 40 comments. View all 107 comments or add a comment.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.