[PATCH] Recognise and use PK to control access to uinput device
Marcel Holtmann
marcel at holtmann.org
Fri Feb 22 20:40:54 PST 2008
Hi Scott,
> The attached patch allows HAL to see the /dev/input/uinput control
> device and use PolicyKit to manage ACLs on it. I've set the default
> policy to allow access from the active console users.
<snip>
> +static gboolean
> +misc_compute_udi (HalDevice *d)
> +{
> + gchar udi[256];
> +
> + hal_util_compute_udi (hald_get_gdl (), udi, sizeof (udi),
> + "/org/freedesktop/Hal/devices/uinput");
> + hal_device_set_udi (d, udi);
> + hal_device_property_set_string (d, "info.udi", udi);
> + return TRUE;
> +}
this looks too hackish to me since we certainly have more than uinput
under misc character devices.
Regards
Marcel
More information about the hal
mailing list