On Fri, Sep 30, 2011 at 10:30, James Hunt <james.hunt@xxxxxxxxxx> wrote: > Working on the Ubuntu bug below where a battery unit is exposing non-printable characters via udev > made me wonder: is the expected character encoding for all udev messages ASCII? Or is the > expectation that the kernel simply acts as a pass-through (such that it is the responsibility of > userspace to determine the exact meaning of such messages)? If ASCII is expected, should this be > made manifest somewhere? > > https://bugs.launchpad.net/ubuntu/+source/upstart/+bug/829980 > > I'm happy to provide a kernel patch for the bug above, but need to understand whether the kernel > should be sanitizing udev message content, or leaving that up to userspace. There are no rules really. Especially not about valid utf8 encoding, or printable chars only. If you use D-Bus to transport udev properties as D-Bus strings, you need to make sure they are valid utf8, or use byte arrays instead of strings. Kay -- To unsubscribe from this list: send the line "unsubscribe linux-hotplug" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html