Red Hat Bugzilla – Bug 167517
NetworkManager dies when it discovers a WLAN with a non-UTF-8 ESSID
Last modified: 2007-11-30 17:11:13 EST
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.10) Gecko/20050720 Fedora/1.0.6-1.1.fc4 Firefox/1.0.6
Description of problem:
NetworkManager works fine at the office, but just dies a few seconds after being (re)started at home, with the following log message:
NetworkManager: nm_dbus_escape_object_path: assertion `g_utf8_validate
(utf8_string, -1, NULL)' failed
This crash happens every time; it does not seem to be a problems which comes and goes.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. Set up an AP with a (public) ESSID containing an iso-8859-1 special character.
2. Let NetworkManager scan all WLANS
3. Watch it crash
The computer I experience the problem on is a Dell Latitude X1, with an Intel Corporation PRO/Wireless 2200BG WLAN card. Distribution is updated FC4.
After some digging around, I suspect this is caused by the neighbours WLAN,
which is called "Companyname TrÃ¥dlÃ¸s", encoded as iso-8859-1. ("TrÃ¥dlÃ¸s" is
Norwegian for "wireless", so it's probably not that uncommon.)
I can't very well knock on their door and ask them to turn their network off, so
I haven't been able to test this in other ways than observing that
NetworkManager works reliably in some places (like the office), and it reliably
crashes in others (at home), without me changing any of the configuration on the
PC. This should be easy enough to test for anyone having a space WLAN access
point lying around, though. (Although, if the speculation is correct, your
colleagues might not be able to check their email while you test. :-)
*** Bug 167514 has been marked as a duplicate of this bug. ***
*** Bug 167515 has been marked as a duplicate of this bug. ***
*** Bug 167516 has been marked as a duplicate of this bug. ***
Sorry about the duplicate submissions; Bugzilla gave me "internal server error"
when I tried to submit the bug the first three times. I then split the
description in two, and put some of it into a separate comment field (comment #1
here), which made it stop crashing. It seems it was submitted anyway, though. :)
Created attachment 121967 [details]
Make sure NetworkManager does not crash on an AP with an ISO-8859-1 ESSID
This patch only fixes ESSID's encoded in ISO-8859-1. I do not know if this is
the right fix or if this should be fixed higher up in the stack, but at least
NetworkManager works for me now.
So this isn't technically the correct patch, which would be more complicated,
but I'll have to cook up one that will work. Since NM pushes the ESSID through
DBUS as a string, it has to be UTF8 before it hits dbus. Some more
investigation required, but this should definitely be fixed.
Hey, so if you can't validate the string as utf-8 you could fallback to escaping
each individual byte of the string.
note there is no meaningful way to display the essid to the user if you can't
figure out the encoding of the essid, so maybe we should just prune the list of
Alternatively we could replace undisplayable characters with '?' or U+FFFD or
I don't think it would be a very good idea to prune the offending ESSIDs from
the list. That would make NetworkManager much less useful in most of
Scandinavia - did I mention that "wireless" = "trÃ¥dlÃ¸s"? :) Replacing the
b0rken characters with "?" or something like that would be a much better
solution, I think.
(Does it make sense to try to guess at encoding from the configured timezone or
For the record: NetworkManager 0.6.0 in Fedora Core 5 doesn't seem to have this
problem. At least I haven't been able to make it crash yet. :) Thank you for
fixing the problem!
This report targets the FC3 or FC4 products, which have now been EOL'd.
Could you please check that it still applies to a current Fedora release, and
either update the target product or close it ?